I want solution to this question., JAVA Programming

Assignment Help:

This assignment is based on the principles of clock consistency and associated drifts in a distributed system. You have to create a simulation, running on a single machine, of a simple distributed system involving four process objects (PO). Each PO will contain a logical clock, a concept first proposed by Lamport.1 The concept of the logical clocks and associated synchronization, based on the following rules, will attempt to resolve the clock consistency in this system:
1. Each event (internal, send, or receive) in the system is associated with a time-stamp, based on logical clocks.
2. Each PO, Pi, will have an associated logical clock, LCi. This logical clock is implemented as a simple counter that is incremented whenever an event takes place within that PO. Since a logical clock has a monotonically increasing value, it assigns a unique number to every event. The time stamp of an event is the value of the logical clock for that event. Hence, if an event A occurs before an event B in Pi, then LCi(A) < LCi(B).
3. A Pi will randomly decide if it wants to carry out an internal event or send a message to some other Pj. If it decides to send a message to a randomly selected Pj then it will attach the value of its logical clock to that message. A Pi may also decide to receive a message from another Pj if that Pj has sent a message to the Pi earlier.
4. Whenever a Pj receives a message from another Pi, it will advance its logical clock if the time stamp associated with the incoming message is greater than or equal to the current value of its logical clock, i.e., if Pj, receives a message (event B) from Pi with a time stamp t and LCj(B) = t then Pj should advance its logical clock such that LCj (B) is equal to t + 1.
5. Any Pi, in the system, may exhibit Byzantine or arbitrary failures when it receives a message – e.g., it may choose not to advance its logical clock at all.
Your task is to:
1. Propose the interaction and failure models for this system. Discuss the pros and cons of your design.
2. Simulate this entire environment in C++ or Java using threads. Allow the simulation to reach a steady-state, i.e., run the program for a large number of iterations. During each iteration and at the end of the simulation compare the values of the logical clocks of POs – this comparison should indicate the clock drifts and their synchronizations. Repeat the simulation with different probabilities and access their effects on the clock drifts.
3. Create a brief report that indicates the aforementioned models and the analyses of the results of your simulation.

Related Discussions:- I want solution to this question.

Can a class implementing a remote interface, Can a class implementing a Rem...

Can a class implementing a Remote interface have non remote processes? Ans) Yes. Those processes behave as normal java process operating within the JVM.

What are stored procedures? how is it useful?, A stored procedure is a set ...

A stored procedure is a set of statements/commands which reside in the database. The stored procedure is pre-compiled and keeps the database the effort of parsing and compiling sql

How to finding an applets size, Finding an Applet's Size When running i...

Finding an Applet's Size When running inside a web browser the size of an applet is set through the height and width attributes and cannot be changed by the applet. Several app

Implement the list calss, Your next task is to implement the MovieList clas...

Your next task is to implement the MovieList class that manages the details for a list of DVD Movies read from the specified data file. The constructor will include a parameter tha

What is aop(aspect oriented programming)?, Separating your business logic w...

Separating your business logic with other functionality such as services, Loggers etc, making classess more cohesive.

Conditional statements in javascript, Very frequently when you write code, ...

Very frequently when you write code, you desire to perform distinct actions for different decisions. You can employ conditional statements in your code to do this. In JavaScript

State the verify phase of java program development, State the Verify phase ...

State the Verify phase of Java Program Development Before the bytecodes in an application are executed by the java interpreter, they are verified by the bytecode verifier in

K-means clustering, i) Set the number of data points to 20 and the number o...

i) Set the number of data points to 20 and the number of clusters to 2. Check box Show History. Click on Initialize. Click on Start. Click on Step . Observe which points ch

Build encyption decryption code, Hi, For my network and security class. I ...

Hi, For my network and security class. I have a project where I need to create a program that take an input and encrypts it and then you can also enter that value into another tex

Define in detail the building of webpage, Question 1 Describe the browser ...

Question 1 Describe the browser components and its features Question 2 Define in detail the building of webpage Question 3 How to use forms? Describe with an example

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd