Skip to content

Game Repository & Sprint 2 refactoring#71

Open
the-only-queen-anna wants to merge 9 commits into
developmentfrom
refactoring/game-repository
Open

Game Repository & Sprint 2 refactoring#71
the-only-queen-anna wants to merge 9 commits into
developmentfrom
refactoring/game-repository

Conversation

@the-only-queen-anna
Copy link
Copy Markdown
Collaborator

@the-only-queen-anna the-only-queen-anna commented May 31, 2026

Context

In this PR, some refactoring issues were solved.

Details

  1. the game repository now handles all game-related calls. The remaining calls to web socket handler will be transferred to chatViewModel in Chat View Model #55., closes Use game repository with all game-related requests #58
  2. a websocket session manager was added. this stores the only session in the app, all other controllers (game and chat, to better separate this, will probably be included in Chat View Model #55 ?) use this session through a getter. connect logic is also transferred to the session manager, disconnect can be added there too. closes Game Web Socket Refactoring #60
  3. IP addresses are now no longer hard-coded. Please add the following line to your local.properties SERVER_URL=10.0.2.2:8080/ for emulator, if you test with real devices put in your IP, when you test with the real server (after we have deployed), enter the server domain name. updates or closes IP management #59, depending on how much we want to do there
  4. for IP address handling, local properties were included in the module's build.gradle file.
  5. GameWebSocketHandler was renamed to GameWebSocketController, since that fits its new responsibility better

Changes outside the codebase

Like mentioned above, local.properties has to be edited manually by everybody who tests the frontend. Changes to build.gradle were also made.

Additional information

N/A

@sonarqubecloud
Copy link
Copy Markdown

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.

1 participant