https://github.com/sitetester/user-online-status-notifier
https://github.com/sitetester/user-online-status-notifier
Last synced: over 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/sitetester/user-online-status-notifier
- Owner: sitetester
- Created: 2020-06-09T15:18:15.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2024-03-15T06:08:49.000Z (over 2 years ago)
- Last Synced: 2025-02-07T03:18:13.079Z (over 1 year ago)
- Language: Java
- Size: 21.9 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
This is Java based TCP service, and it satisfies the following points.
1. Start listening for tcp/udp connections.
2. Be able to accept connections.
3. Read json payload ({"user_id": 1, "friends": [2, 3, 4]})
3. After establishing successful connection - it "stores" it in memory.
4. When another connection established with the user_id from the list of any other user's "friends" section, they are notified about it with a message {"online": true}
5. When the user goes offline, his "friends" (if it has any and any of them online) should receive a message {"online": false}