Skip to content

Geo Replicables - Remove RESTful support from UI

Zack Cuddy requested to merge 219417_01-remove-legacy-geo-restful-api-vue into master

What does this MR do and why?

Part 1 of 2 #219417 (closed)
Follow up MR: !132156 (merged)

This change begins to remove in entirety the RESTful support for Geo Replicables (ee/geo_replicables). Due to the sheer size of the deletion the work has been split into two parts:

  1. Vue Components (this MR)
  2. Vuex Store (following MR)

Some Background

When Geo was first implemented we used a RESTful endpoint. As we scaled Geo we made the decision to migrate to a GraphQL endpoint along with the adoption of the Self Service Framework. During the adoption period of the Self Service Framework we opted to support the legacy RESTful implementations. This created a layer of technical debt for the Frontend as we wanted to provide a unified experience in the UI regardless if the data was being served via REST or GraphQL.

However, the time has come that we completely sunset the RESTful implementation in the Frontend now that the RESTful endpoint has been fully removed from our codebase

Changes in this MR

  1. Removal of all references to state.useGraphQl in the .vue files
    • This reduced the complexity of quite a few computed properties.
  2. Replace GlPagination with GlKeysetPagination
    • We no longer need to support RESTful pagination and can simply use the cursors from GraphQl
  3. Remove of ee/app/views/admin/geo/designs/index.html.haml

Screenshots or screen recordings

Designs Redirect

Designs_Redirect

All functionality remains

Functionality

UI remains the same

Before After
Screenshot_2023-09-19_at_3.29.52_PM After

How to set up and validate locally

  1. Fetch and checkout this branch
  2. Setup Geo by following the 1-line installation in the Easy Installation section (How to setup Geo)
  3. Enable Feature Flag Feature.enable(:geo_registries_update_mutation) (if you want to test the Resync/Reverify actions)
  4. Access your Secondary GDK UI
  5. Navigate to the Geo Replication View for Job Artifacts (ex. http://127.0.0.1:3001/admin/geo/sites/2/replication/job_artifacts)
  6. Ensure filtering still works
  7. Ensure buttons still work
  8. Ensure pagination still works

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #219417 (closed)

Edited by Zack Cuddy

Merge request reports

Loading