Skip to content

Use human readable name as cluster's integration_id #888

@shtripat

Description

@shtripat

Currently in tendrl we use an UUID as cluster's integration_id and if multiple clusters maintained by tendrl it becomes tough to identify the clusters.

There is a suggestion to use human readable name as integration_id for clusters. So the flow to use a human readable name integration_id for cluster would be something like below

  1. While node agent detects a cluster which is ready for import, it creates a UUID as temporary detected integration_id for cluster and creates an object /clusters/{detected-integration-id} in etcd with is_managed value as no
  2. When UI triggers the import for this cluster the dialog thrown for import cluster would list this detected_cluster_id and user needs to provide a human readable integration_id value in the dialog. If user doesnt provide a human readable name in dialog the existing detected_integration_id remains as final integration_id for the cluster then onwards. May be UI should shown a warning on the dialog regarding the same saying If no human readable name provided the detected_integration_id would remain as identifier for the cluster and later it wont be possible to change.
  3. UI submits the import cluster request with a flag saying if the detected_cluster_id was replaced with human readable name and the new integration_id. API layer adds a check to find if a cluster with given new integration_id in request, already exists. If so API raises an error saying cluster with this name already exists. This check should happen only if UI send the flag detected_integration_id_overriden as yes
  4. In back-end the import cluster flow adds a pre check atom to do the check for pre-existence of cluster with new integration_id in parameters and fail if so. This pre check also runs only if detected_integration_id_overriden is set as yes in request.
  5. The import cluster flow replaces the object /clusters/{detected_integration_id} with /clusters/{human_readable_integration_id} in etcd based on detected_integration_id_overriden field set as yes. If the field detected_integration_id_overriden is not set as yes in request the old /clusters/{detected_integartion_id} remains as is.
  6. After this import flow runs as usual and continues.

With this there are no other changes required at back-end or any other components and it should be seamlessly working with human readable ntegration_id for cluster.

@r0h4n @nthomas-redhat @gnehapk @shirshendu @GowthamShanmugam @cloudbehl comments/thoughts?

@julienlim if we go ahead with this model, we would need UX changes for the import cluster dialog to capture the human readable integration_id for cluster.

Lets have all the discussion points captured here and go ahead based on the decision taken.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions