Reference no: EM133494880
Question 1. Develop a centralized distributed mutual exclusion application that allows clients to access a shared resource, a file in this assignment, without interfering with each other's. The shared resource will be a text file that the clients will update by adding to the file their IDs and the result of a time-consuming task of your choice, e.g, nth prime number. Your application should do the following:
o Develop your application following the description covered in class and provided in Slide 12-8. You can use any interposes communication you deem appropriate for your application: UDP, TCP, Multicast, Rest API, ...
o Clients randomly will require access to the shared resource.
o To slow down your clients while accessing the shared resource and hence simulate a critical section, make sure that clients perform some time-consuming tasks, then write to the text file their ID and the result of this task.
o Next, do the following:
a. Run your application that generates multiple requests and measure their execution times while in the critical section. Execute multiple clients, with each one generating many requests.
b. Analyze the execution times per client, for the whole system, and in function of the requests made to the server.