Remove code_suggestions_direct_access_cloud_connected flag
What does this MR do and why?
This MR removes the code_suggestions_direct_access_cloud_connected feature flag and keeps the feature.
The flag controlled the rollout of code completion direct access tokens on cloud-connected instances. The flag has been enabled on GitLab.com for several days. The rollout is complete, and the metrics are stable. Direct access tokens are now always available on instances without a self-hosted AI Gateway.
The Ai::FeatureSetting check for Duo Self-Hosted instances stays in place: instances with a self-hosted AI Gateway and no pinned or vendored model still get the 400 error with the "assign a model" message.
After the merge
When this MR is deployed, we can delete the flag from all environments:
/chatops gitlab run feature delete code_suggestions_direct_access_cloud_connected --dev --pre --staging --staging-ref --productionReferences
- Rollout issue: #608480 (closed)
- Feature flag introduced in: !248914 (merged)
- Related to: #605887 (closed)
Screenshots or screen recordings
No UI changes.
How to set up and validate locally
-
Make sure your GDK has no self-hosted AI Gateway URL and no code completions feature setting:
# rails console Gitlab::CurrentSettings.update!(ai_gateway_url: nil) ::Ai::FeatureSetting.find_by(feature: :code_completions)&.destroy -
Call the endpoint with a user who has a Duo seat and a default Duo namespace:
curl -X POST -H "Authorization: Bearer $TOKEN" \ "http://gdk.test:3000/api/v4/code_suggestions/direct_access" -
Expected: 201 with a token. The feature flag state has no effect anymore.
MR acceptance checklist
Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.