Show Orbit indexing status in the Orbit UI with the new status RPCs

Problem to Solve

Orbit now reports indexing status per domain, with a ready, syncing, or error phase and the number of failed projects. Rails still calls GetGraphStatus, so users cannot see whether their data is ready or whether some of it failed.

Proposed Solution

  • Bump gitlab-orbit-proto to ~> 0.133.0.
  • Call GetIndexingStatus for the phase of each domain. Send up to 100 group or project paths in one call.
  • Call GetItemCounts only for the Explore counts. The server caches the result for 5 minutes.
  • Show the phase of each domain in the Index status tab and on the admin page. Show ERROR and the number of failed projects for source code.
  • Rails owns the domain titles and summaries, for translation.

Tracked in gitlab-org/orbit/knowledge-graph#1281 (closed).

Agent context

Rails code that calls the status today:

  • ee/lib/analytics/knowledge_graph/grpc_client.rb (gRPC client)
  • ee/lib/api/orbit/data.rb (graph_status API)
  • ee/app/assets/javascripts/orbit/components/namespace_index_card.vue, ee/app/assets/javascripts/orbit/utils/graph_stats.js, ee/app/assets/javascripts/orbit/api/orbit_api.js
  • Gemfile: gitlab-orbit-proto ~> 0.130.0

Proto (crates/orbit-server/proto/orbit.proto in knowledge-graph):

  • GetIndexingStatusRequest.traversal_paths: 1 to 100 paths. The caller must have access to each path; admins can send any path.
  • IndexingPhase: UNKNOWN, NOT_STARTED, SYNCING, READY, ERROR.
  • DomainIndexingStatus{name, phase, projects}. projects (indexed, total_known, gaps) is only set for source_code.
  • GetItemCountsResponse.domains: domains, then entities. No totals.
  • GetGraphStatus keeps its contract, so the switch can happen one view at a time.

Open question: a plan that never writes a row stays NOT_STARTED. To report it as a gap, the server needs the time the namespace was enabled. Rails may need to send knowledge_graph_enabled_namespaces.created_at in the request (see the Orbit follow-up issue linked on gitlab-org/orbit/knowledge-graph#1281 (closed)).