Question
Write a Java program: A car sales company requires a server to store(tread save all its car data (store car data on the server) and
Write a Java program:
A car sales company requires a server to store(tread save all its car data (store car data on the server) and share it with its sales personnel. For the purposes of this assignment each car has the following attributes: registration, make, price, mileage, and forSale (use a Boolean- true for forSale and false for sold).
..
1) A salesperson can add a new car to the system (to the server) and read the requests.
2) Sell a car or/and request information from the system. Sample requests are: Cars for sale, Cars of a given make, and Total value of all sales. (could use arrayBlockingQueue, as it is concurrent already, or use locks)
3)No user intervention needed, just server/client(salesperson) need,
.
All cars added to the system should be stored in a thread-safe shared data structure on the server. You can create one client that performs all requests above, one after the other. No need for user intervention. Your task is to build a working model of this system.
...
Notes
1. No log on/off required for users.
2. For this assignment you should add approximately 15 cars to the system.
#Java#Conncurrency#Sockets#SharedMemory#ParrallelStreams
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started