An application that acts as an intermediary between a server and clients (drivers), providing them with traffic information (e.g., whether their speed is legal or if there's an accident on their route), along with optional updates about sports, fuel prices, or weather conditions.
Implement a system capable of managing traffic and providing virtual information to drivers. Drivers will also be able to report traffic incidents to the system. These updates will then be sent to all traffic participants.
Each car will automatically send information about its current speed to the system. The system will then notify each driver about speed restrictions (possibly due to a traffic jam).
Additionally, each driver can subscribe to receive information about:
- Weather updates
- Sports events
- Fuel prices at gas stations
Actors:
- A server system that waits for incoming connections
- Multiple client connections (from drivers)
Activities:
- The server sends information to all clients about:
- The speed they should maintain on a particular road segment
- The server sends information about weather, sports events, and fuel prices only to clients who have opted in for these options
- A client reports an accident on Lapusneanu Street No. 73, the server records the message and broadcasts it to all clients
- All clients send their current speed to the server (with a frequency of once every minute, the information is updated)
9.50 / 10