Skip to content

Feature/145 flyway migration#146

Merged
XtophB merged 11 commits into
developmentfrom
feature/145-flyway-migration
Jun 2, 2026
Merged

Feature/145 flyway migration#146
XtophB merged 11 commits into
developmentfrom
feature/145-flyway-migration

Conversation

@XtophB
Copy link
Copy Markdown
Collaborator

@XtophB XtophB commented Jun 2, 2026

Context

This PR contains the addition of a flyway script to create the tables in the DB.

Description

We have 5 tables storing the following:

  • lobby
  • player
  • game_state
  • card (each lobby has 25 cards)
  • chat_message (debatable if we want to store chat or not)

Changes in the code base

  • Add flyway migration script

Changes outside the code base

N/A

Additional information

Commands

  1. docker compose up -d --build
  2. ./mvnw spring-boot:run
  3. In IDE -> DB (Right side) -> Properties -> Test Connection
  4. docker compose down
image

XtophB added 9 commits June 2, 2026 00:27
We need to decide as a team if duplicates are allowed or not. For now we leave the constraint as is, can be deleted in t he future
Turns out big variant is not as expensive as expected. As most systems run on 64 bit processors, it might have performance increase.
Additionally
(source reddit)
Note: each game will have 25 entries in the card table
Need to discuss with team if we want to store chat in the first place.
If yes, we need to consider if we want to store time stamp or not
Since it is a 1:1 relation, the id is unnecessary and lobby_code is sufficient
While the diskspace usage stays the same for all values sub 255, the searching might suffer from using large sizes.
Also security concerns/ malicious inputs/ wrong inputs can be minimized by not allowing a standard large varchar size
tasaje1
tasaje1 previously approved these changes Jun 2, 2026
Copy link
Copy Markdown
Collaborator

@tasaje1 tasaje1 left a comment

Choose a reason for hiding this comment

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

in meeting gezeigt lgtm :))

Copy link
Copy Markdown
Collaborator

@the-only-queen-anna the-only-queen-anna left a comment

Choose a reason for hiding this comment

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

LGTM, gemeinsam im discord reviewed.

@XtophB XtophB dismissed stale reviews from the-only-queen-anna and tasaje1 via 4b8a45a June 2, 2026 18:55
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud Bot commented Jun 2, 2026

Copy link
Copy Markdown
Collaborator

@tasaje1 tasaje1 left a comment

Choose a reason for hiding this comment

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

ok

Copy link
Copy Markdown
Collaborator

@the-only-queen-anna the-only-queen-anna left a comment

Choose a reason for hiding this comment

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

LGTM

@XtophB XtophB merged commit 1d6c777 into development Jun 2, 2026
2 checks passed
@XtophB XtophB linked an issue Jun 2, 2026 that may be closed by this pull request
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.

Initial Flyway Migration Script

3 participants