feat: add orbit_use_legacy_tools FF to gate legacy Orbit tool execution
What does this MR do and why?
Adds orbit_use_legacy_tools feature flag (kill-switch, default enabled) to gate legacy Orbit tools (query_graph, get_graph_schema, get_graph_status) in three paths that orbit_mcp_command_tools does not cover:
- MCP execution (
tools/call) — legacy tools were callable even when hidden fromtools/list - AI Catalog picker — legacy tools were always selectable by custom agent authors
- DWS pre-approved tools — legacy tools were always pre-approved/injected
When disabled, legacy tools become genuinely unreachable. When enabled (default), behavior is unchanged.
Notes
- The flag is defined as an
opskill-switch (default enabled).gitlab_com_deriskcannot bedefault_enabled: true, and a default-on kill-switch is exactly theopstype. get_graph_statusis executable but never advertised bytools/list; it is covered via a newToolCatalog::ALL_LEGACY_TOOL_NAMESconstant.- The AI Catalog picker (
orbit_tool_names) is a global/class-level method, so it gates on the instance-wide rollout state (:instanceactor). Execution and DWS paths use the per-user actor.
Edge case: discovery vs. execution divergence
When orbit_use_legacy_tools=false and orbit_mcp_command_tools=false, tools/list still advertises the legacy tools (discovery is gated only by orbit_mcp_command_tools) while tools/call rejects them with "Unknown tool". This is acceptable: the two flags address different concerns, and this combination is unlikely in practice since the intended rollout is command-tools-on. The deprecation switch deliberately makes execution the hard boundary rather than relying on discovery being hidden.
Relates to https://gitlab.com/dgruzd/tasks/-/work_items/2791