Skip to content

ci: add hybrid mode test, document hybrid config#69

Merged
aparajon merged 1 commit intomainfrom
hybrid-mode-test
May 6, 2026
Merged

ci: add hybrid mode test, document hybrid config#69
aparajon merged 1 commit intomainfrom
hybrid-mode-test

Conversation

@aparajon
Copy link
Copy Markdown
Collaborator

@aparajon aparajon commented May 1, 2026

Summary

Verify that SchemaBot supports hybrid mode — both local (direct MySQL) and gRPC (remote Tern) clients from a single instance.

  • Integration test exercises config validation, deployment resolution, and plan/apply through both paths simultaneously
  • Document hybrid mode in docs/configuration.md with example config

No code changes — hybrid mode already works by design. The TernClient() routing checks the databases config first (local client), then falls back to tern_deployments (gRPC client).

🤖 Generated with Claude Code

Copilot AI review requested due to automatic review settings May 1, 2026 21:57
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds coverage and documentation for SchemaBot “hybrid mode”, where a single service instance can route to both local (direct DB) and gRPC (remote Tern) clients depending on configuration.

Changes:

  • Added an integration test suite that plans/applies against both a locally configured database and a gRPC-routed database in the same run.
  • Added config validation/routing-related tests for hybrid configurations (currently under the integration build tag).
  • Documented hybrid mode configuration and routing behavior in docs/configuration.md.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.

File Description
integration/hybrid_mode_test.go New integration test coverage for hybrid local+gRPC routing, plus config/routing assertions.
docs/configuration.md Documents how to configure and reason about hybrid mode routing.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread integration/hybrid_mode_test.go Outdated
Comment thread integration/hybrid_mode_test.go Outdated
Comment thread integration/hybrid_mode_test.go Outdated
Comment thread docs/configuration.md Outdated
@aparajon aparajon force-pushed the hybrid-mode-test branch from 6ed032c to a0a7c8f Compare May 5, 2026 22:32
@aparajon aparajon marked this pull request as ready for review May 5, 2026 22:41
@aparajon aparajon requested a review from morgo as a code owner May 5, 2026 22:41
Verify that a single SchemaBot instance can route requests to both
LocalClient (direct MySQL) and GRPCClient (remote Tern) simultaneously.
Both modes can be configured together — databases in the `databases`
section use direct connections, everything else routes through
`tern_deployments`.

Tests cover config validation, deployment resolution, and end-to-end
plan/apply through both paths.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@aparajon aparajon force-pushed the hybrid-mode-test branch from a0a7c8f to 8b89a47 Compare May 5, 2026 22:43
@aparajon aparajon changed the title test(integration): add hybrid mode test, document hybrid config ci: add hybrid mode test, document hybrid config May 5, 2026
@aparajon aparajon merged commit 11b8a02 into main May 6, 2026
23 checks passed
@aparajon aparajon deleted the hybrid-mode-test branch May 6, 2026 20:00
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.

3 participants