Skip to content
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

"Team" entity refactor #553

Open
sei-bstein opened this issue Nov 21, 2024 · 0 comments
Open

"Team" entity refactor #553

sei-bstein opened this issue Nov 21, 2024 · 0 comments
Assignees
Labels
chores Keeping our project tidy, current, and building

Comments

@sei-bstein
Copy link
Contributor

We talk about this a lot internally, but I noticed we don't have an issue explicitly dedicated to it.

Currently, teams get an ID, but are not actual entities - they don't have a table and are thus not subject to typical relational constraints that can be useful for system stability, efficient queries, etc. This has caused a number of bugs over the years, and results in some pretty gnarly workarounds that result in DB denormalization.

Proposed solution is to:

  • Make Team a first-class entity
  • Move relevant fields from Player to it (session times, scores, challenge completion, team name, whatever else makes sense)
  • Create a FK constraint from player to team
  • Refactor to take advantage

This is a large lift but is really important for longterm application health. We'll address when it makes sense.

@sei-bstein sei-bstein added the chores Keeping our project tidy, current, and building label Nov 21, 2024
@sei-bstein sei-bstein self-assigned this Nov 21, 2024
@sei-bstein sei-bstein mentioned this issue Nov 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chores Keeping our project tidy, current, and building
Projects
None yet
Development

No branches or pull requests

1 participant