Create a print queue simulation to run within Linux/Unix.
Consists of two processes. A producer and a Consumer.
The producer must create a series of child processes of which the PID will represent the print job number and stored within a priority queue. Job priority should be between 0-5 0 being highest, 5 lowest.
This queue should be made available to the consumer by the means on IPC to allow it to despool.
Consumer should be configurable through command line arguments to change the size of the queue and the maximum number of jobs to be created on each cycle.
The consumer will run separately from the producer in a different console window and will simulate despooling.
It should also be configurable with command line arguments to specify the maximum number of jobs to be deleted from the queue during a cycle.
it should perform the following. Find and delete a specified number of jobs from the queue. print a notification that it has done so. Kill the process linked to that PID. Remove the process' entry from the queue
8 freelancere byder i gennemsnit £132 for dette job
I have been doing network programming, for a long [url removed, login to view], I solve these types of questions very regularly to keep in touch with the subject.