Skip to content

use named constants to define columns containing IDs and generic values#678

Merged
motus merged 12 commits into
microsoft:mainfrom
motus:sergiym/db/len_const
Feb 21, 2024
Merged

use named constants to define columns containing IDs and generic values#678
motus merged 12 commits into
microsoft:mainfrom
motus:sergiym/db/len_const

Conversation

@motus

@motus motus commented Feb 14, 2024

Copy link
Copy Markdown
Member

Also, make objectives.optimization_target use the new _LEN_ID constant to make sure it is not too long to be used as a primary key in MySQL (issue #677)

Closes #677

@motus motus requested a review from a team as a code owner February 14, 2024 22:17
@motus motus self-assigned this Feb 14, 2024
@motus motus added bug Something isn't working ready for review Ready for review mlos-bench labels Feb 14, 2024
@motus motus enabled auto-merge (squash) February 14, 2024 22:34
Comment thread mlos_bench/mlos_bench/storage/sql/schema.py Outdated
Comment thread mlos_bench/mlos_bench/storage/sql/schema.py Outdated
@motus

motus commented Feb 15, 2024

Copy link
Copy Markdown
Member Author

bumped up the ID and value lengths to 512 and 1024 correspondingly. That's an increase from our current 255/255 limit that would still allow us to use optimization_target in a primary key on MySQL

@motus motus merged commit e7a9c44 into microsoft:main Feb 21, 2024
@motus motus deleted the sergiym/db/len_const branch February 21, 2024 22:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working mlos-bench ready for review Ready for review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

objectives.optimization_target column is too long to be in the primary key for MySQL

2 participants