Conversation
Collaborator
Author
|
Jenkins choked yesterday for some odd reason and took ages to finish. I re-ran it today just in case and now the CI is all green and ready for review. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Brief description
This PR introduces
client_versiontracking for online players. This field allows the system to identify the game build version during the "ping" process, ensuring better matchmaking isolation and helping to prevent desyncs between incompatible client versions.This change was requested from the lead of the project to ensure that incompatible versions wouldn't be able to match with each other.
The data is persisted in the Redis cache and is available for filtering when retrieving the list of online players.
Change list
Domain Model Update: Addedclient_versionto theOnlinePlayerdomain class and applied@Expose()decorators to ensure property visibility during serialization.DTO Validation: Updated theAddOnlinePlayerpayload class with@IsString()and@IsOptional()decorators to validate incoming client version data from the /ping endpoint.Service Logic:
Modified
addPlayerOnlineto extractclient_versionfrom the request and include it in the Redis payload.Updated
getOnlinePlayersto support optional filtering byclient_version.Infrastructure & Cache
Redis Payload: Updated the JSON schema stored in Redis to include the new version string.

Test & Verification
Manual Verification: Confirmed via server logs that
client_versionis correctly received by the service and retrieved from the cache.Postman Testing: Verified that sending
client_versionin a POST request results in the data being successfully processed by the backend.