Skip to content

Fix endpoint Validate and Save persisting invalid values - #943

Open
mihaelabalutoiu wants to merge 4 commits into
cloudbase:mainfrom
mihaelabalutoiu:fix-endpoint-validate-and-save
Open

mihaelabalutoiu wants to merge 4 commits into
cloudbase:mainfrom
mihaelabalutoiu:fix-endpoint-validate-and-save

Conversation

@mihaelabalutoiu

@mihaelabalutoiu mihaelabalutoiu commented Sep 23, 2026 •

Copy link
Copy Markdown
Member

Previously, the Validate and Save button saved the endpoint without waiting for validation, so invalid values were kept, and a later attempt could show the error of the previous values.

This PR implements the following:

  • Validate the proposed endpoint connection info:
    • send the form's platform, connection_info and mapped_regions to the new /endpoints/actions API instead of validating a stored endpoint.
  • Save endpoints only after they pass validation:
    • create or update the endpoint only if validation passes. When validation fails, nothing is saved and the stored endpoint is unchanged.
  • Fix endpoint Validate and Save persisting invalid values:
    • the modal keeps the user's values, ignores repeated submits, shows "Saving ..." while saving and closes only after the endpoint is saved.
  • Update the unit and Cypress tests.
  • Allow running the build workflow manually.

@mihaelabalutoiu
mihaelabalutoiu marked this pull request as draft September 28, 2026 12:56
Signed-off-by: Mihaela Balutoiu <mbalutoiu@cloudbasesolutions.com>
Validate the endpoint's platform and connection info instead of the
saved endpoint, so it can be checked before it is saved.

Signed-off-by: Mihaela Balutoiu <mbalutoiu@cloudbasesolutions.com>
Add `validateAndSave`, which validates the proposed values and only
creates or updates the endpoint if they are valid, so a failed
validation leaves nothing saved.

Signed-off-by: Mihaela Balutoiu <mbalutoiu@cloudbasesolutions.com>
Validate the endpoint before saving it and keep the user's values
when the validation fails.

Signed-off-by: Mihaela Balutoiu <mbalutoiu@cloudbasesolutions.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant