How farahchannir/testwork works
This repository implements a TCP/JSON-RPC auction client and server, plus a console simulator that exercises them. In the interactive workflow, a user chooses to start an auction or place a bid; the client invokes the server, which registers auction products or broadcasts bids to connected clients. The server also exposes product and auction-conclusion notifications, with client-side handlers for updates and winners. The sampled server code does not show a bid-validation or auction-closing trigger, and its product-price notification handler is not present in the excerpts, so those connections are not inferred.
Main entry points: AuctionClient.cs Client RPC · AuctionServer.cs RPC and auctions · P2PAuctionSimulator/Program.cs Scenario runner · Auction-Client/Program.cs Interactive menu
Components 9
Auction client
- Interactive menu
Auction-Client/Program.cs - Client RPC
Auction-Client/Models/AuctionClient.cs - Client state
Auction-Client/Models/AuctionClient.cs
Auction server
- Server startup
Auction-Server/Program.cs - RPC and auctions
Auction-Server/Models/AuctionServer.cs - Auction state
Auction-Server/Models/AuctionServer.cs - Bid record
Auction-Server/Models/Bid.cs
Simulation
- Scenario runner
P2PAuctionSimulator/Program.cs
Other components
- Console user
Connections 9
- Console user → Interactive menu: chooses actions
- Interactive menu → Client RPC: starts or bids
- Client RPC → RPC and auctions: invokes RPC
- Server startup → RPC and auctions: starts listener
- RPC and auctions → Auction state: updates state
- RPC and auctions → Client RPC: notifies clients
- Client RPC → Client state: records winners
- Scenario runner → RPC and auctions: starts server
- Scenario runner → Client RPC: runs scenario