Skip to content

Add engine flag to cluster size list#1110

Merged
mscoutermarsh merged 3 commits intomainfrom
add-engine-flag-to-cluster-size-list
Aug 27, 2025
Merged

Add engine flag to cluster size list#1110
mscoutermarsh merged 3 commits intomainfrom
add-engine-flag-to-cluster-size-list

Conversation

@teknogeek0
Copy link
Copy Markdown
Contributor

adds engine parameter to allow for Postgres sizes to be shown

teknogeek0 and others added 2 commits August 27, 2025 17:12
This allows users to list cluster sizes for both MySQL and PostgreSQL databases.

- Add --engine flag with mysql/postgresql options (defaults to mysql)
- Add WithPostgreSQL() function to append postgresql=true query parameter
- Update help text and flag completion
- Add tests for both MySQL and PostgreSQL cluster listing
- Fix completions function to properly handle list options

Resolves issue where PostgreSQL database creation fails with "Cluster size is invalid" error.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
Replace custom WithPostgreSQL() implementation with the official SDK function:

- Remove custom WithPostgreSQL() function
- Remove net/url import (no longer needed)
- Use planetscale.WithPostgreSQL() instead of local implementation
- Cleaner code that follows proper architecture patterns

Depends on planetscale-go SDK having WithPostgreSQL() function available.
@teknogeek0 teknogeek0 requested a review from a team as a code owner August 27, 2025 21:40
@mscoutermarsh mscoutermarsh merged commit c717815 into main Aug 27, 2025
1 check passed
@mscoutermarsh mscoutermarsh deleted the add-engine-flag-to-cluster-size-list branch August 27, 2025 21:49
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.

2 participants