-
Notifications
You must be signed in to change notification settings - Fork 7
Add TiDB and AlloyDB to ScalarDB core and ScalarDB Cluster samples #86
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add TiDB and AlloyDB to ScalarDB core and ScalarDB Cluster samples #86
Conversation
Summary of ChangesHello @Torch3333, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request significantly expands ScalarDB's compatibility by introducing support and sample configurations for TiDB and AlloyDB. The changes provide developers with ready-to-use Docker Compose setups for AlloyDB and clear, commented-out configuration examples for both databases, streamlining the process of integrating ScalarDB with these popular distributed and cloud-native data stores. Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request adds configuration for TiDB and AlloyDB to the ScalarDB core and cluster samples. The changes are a good addition, but I've found a port conflict in both docker-compose.yaml files. The new alloydb service is configured to use host port 5432, which is already in use by the existing postgres service. This would cause docker-compose up to fail. I've provided suggestions to fix this by using a different host port for AlloyDB. For the scalardb-sample, a corresponding change in database.properties is also suggested.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR adds support for TiDB and AlloyDB databases to the ScalarDB sample configurations. TiDB is configured to run externally via the tiup CLI tool, while AlloyDB is added as a Docker service using the AlloyDB Omni container image. The changes enable developers to test ScalarDB functionality with these additional database backends.
- Added AlloyDB Docker service definitions to both sample compose files
- Added JDBC connection configurations for TiDB and AlloyDB to properties files
- Configured AlloyDB with PostgreSQL-compatible settings and ICU locale support
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 5 comments.
| File | Description |
|---|---|
| scalardb-sample/docker-compose.yml | Adds AlloyDB service with PostgreSQL compatibility using google/alloydbomni:16 image |
| scalardb-sample/database.properties | Adds commented configuration examples for TiDB (MySQL-based) and AlloyDB (PostgreSQL-based) JDBC connections |
| scalardb-cluster-standalone-mode/scalardb-cluster-node.properties | Adds TiDB and AlloyDB configuration blocks with Docker networking support (host.docker.internal and container names) |
| scalardb-cluster-standalone-mode/docker-compose.yaml | Adds AlloyDB service definition matching the scalardb-sample configuration |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
scalardb-cluster-standalone-mode/scalardb-cluster-node.properties
Outdated
Show resolved
Hide resolved
scalardb-cluster-standalone-mode/scalardb-cluster-node.properties
Outdated
Show resolved
Hide resolved
scalardb-cluster-standalone-mode/scalardb-cluster-node.properties
Outdated
Show resolved
Hide resolved
feeblefakie
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thank you!
brfrn169
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thank you!
komamitsu
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! 👍
Description
This adds TiDB and AlloyDB to ScalarDB core and ScalarDB Cluster samples.
Since TiDB is not started with Docker but using the
tiupCLI, this does not add TiDB to the Docker compose files.Note
Please review this alongside this PR https://github.com/scalar-labs/docs-internal-scalardb/pull/1972 on the ScalarDB internal doc repository.
Related issues and/or PRs
Changes made
Checklist
Additional notes (optional)