EndpointSlice ================================== .. toctree:: :maxdepth: 2 :caption: Contents: ======== Functions --------- set +++ Set any specific field to a value **Args** * \*\*kwargs * Arbitrary list of keys as variables in formation of YAML path separated by underscores with their assocaited values. For example, to set the value at .. code-block:: JSON { "spec": { "template": { "spec": "" } } } use .. code-block:: Python obj.set(spec_template_spec="foobar") * You can also specify an incomplete path and k8sGen will attempt to find a unique location whose ending path matches what you have specified. For the case of the above structure, running .. code-block:: Python obj.set(template_spec="foobar") will set the same location because the only path that ends in 'template/spec' is 'spec/template/spec' **Returns** List of return values for each variable set Possible return values include: * True : value was set successfully * (False, 'invalid key name') : the key you are trying to set does not exist for this object * (False, 'abniguous key name') : the key you are trying to set does not refer to a unique location get +++ Get the values that have been set for specific fields **Args** * \*args * Arbitrary list of keys as variables in formation of YAML path separated by underscores **Returns** List of return values for each variable set Possible return values include: * {Value} : The key's value * (False, 'invalid key name') : the key you are trying to set does not exist for this object Key Names and Types ------------------- +---------------------------------------------+--------------------------+ | Key | Type | +=============================================+==========================+ | addressType | | +---------------------------------------------+--------------------------+ | apiVersion | discovery.k8s.io/v1beta1 | +---------------------------------------------+--------------------------+ | endpoints_addresses | <[]string> | +---------------------------------------------+--------------------------+ | endpoints_conditions_ready | | +---------------------------------------------+--------------------------+ | endpoints_hostname | | +---------------------------------------------+--------------------------+ | endpoints_targetRef_apiVersion | | +---------------------------------------------+--------------------------+ | endpoints_targetRef_fieldPath | | +---------------------------------------------+--------------------------+ | endpoints_targetRef_kind | | +---------------------------------------------+--------------------------+ | endpoints_targetRef_name | | +---------------------------------------------+--------------------------+ | endpoints_targetRef_namespace | | +---------------------------------------------+--------------------------+ | endpoints_targetRef_resourceVersion | | +---------------------------------------------+--------------------------+ | endpoints_targetRef_uid | | +---------------------------------------------+--------------------------+ | endpoints_topology | | +---------------------------------------------+--------------------------+ | kind | EndpointSlice | +---------------------------------------------+--------------------------+ | metadata_annotations | | +---------------------------------------------+--------------------------+ | metadata_clusterName | | +---------------------------------------------+--------------------------+ | metadata_creationTimestamp | | +---------------------------------------------+--------------------------+ | metadata_deletionGracePeriodSeconds | | +---------------------------------------------+--------------------------+ | metadata_deletionTimestamp | | +---------------------------------------------+--------------------------+ | metadata_finalizers | <[]string> | +---------------------------------------------+--------------------------+ | metadata_generateName | | +---------------------------------------------+--------------------------+ | metadata_generation | | +---------------------------------------------+--------------------------+ | metadata_labels | | +---------------------------------------------+--------------------------+ | metadata_managedFields_apiVersion | | +---------------------------------------------+--------------------------+ | metadata_managedFields_fieldsType | | +---------------------------------------------+--------------------------+ | metadata_managedFields_fieldsV1 | | +---------------------------------------------+--------------------------+ | metadata_managedFields_manager | | +---------------------------------------------+--------------------------+ | metadata_managedFields_operation | | +---------------------------------------------+--------------------------+ | metadata_managedFields_time | | +---------------------------------------------+--------------------------+ | metadata_name | | +---------------------------------------------+--------------------------+ | metadata_namespace | | +---------------------------------------------+--------------------------+ | metadata_ownerReferences_apiVersion | | +---------------------------------------------+--------------------------+ | metadata_ownerReferences_blockOwnerDeletion | | +---------------------------------------------+--------------------------+ | metadata_ownerReferences_controller | | +---------------------------------------------+--------------------------+ | metadata_ownerReferences_kind | | +---------------------------------------------+--------------------------+ | metadata_ownerReferences_name | | +---------------------------------------------+--------------------------+ | metadata_ownerReferences_uid | | +---------------------------------------------+--------------------------+ | metadata_resourceVersion | | +---------------------------------------------+--------------------------+ | metadata_selfLink | | +---------------------------------------------+--------------------------+ | metadata_uid | | +---------------------------------------------+--------------------------+ | ports_appProtocol | | +---------------------------------------------+--------------------------+ | ports_name | | +---------------------------------------------+--------------------------+ | ports_port | | +---------------------------------------------+--------------------------+ | ports_protocol | | +---------------------------------------------+--------------------------+ JSON fields ----------- .. code-block:: JSON { "addressType": "", "apiVersion": "discovery.k8s.io/v1beta1", "endpoints": [ { "addresses": "<[]string>", "conditions": { "ready": "" }, "hostname": "", "targetRef": { "apiVersion": "", "fieldPath": "", "kind": "", "name": "", "namespace": "", "resourceVersion": "", "uid": "" }, "topology": "" } ], "kind": "EndpointSlice", "metadata": { "annotations": "", "clusterName": "", "creationTimestamp": "", "deletionGracePeriodSeconds": "", "deletionTimestamp": "", "finalizers": "<[]string>", "generateName": "", "generation": "", "labels": "", "managedFields": [ { "apiVersion": "", "fieldsType": "", "fieldsV1": "", "manager": "", "operation": "", "time": "" } ], "name": "", "namespace": "", "ownerReferences": [ { "apiVersion": "", "blockOwnerDeletion": "", "controller": "", "kind": "", "name": "", "uid": "" } ], "resourceVersion": "", "selfLink": "", "uid": "" }, "ports": [ { "appProtocol": "", "name": "", "port": "", "protocol": "" } ] }