Abstract:
A system that includes one or more priority failure detectors may be included that detect node or process failures in the distributed computer network. The system has a fault-tolerant, client-server architecture where a client process presents a particular consensus problem to one or more server processes to solve such a consensus based problem. The system assigns priority levels to processes involved in a consensus session and controls the frequencies of their heartbeat status messages based on their respective priority levels. By controlling the frequencies, the reliability of the network is enhanced and the overall message load on the even bus is reduced to a minimum number. The system also discloses a name service that assigns unique logical identities to all processes in a consensus session. Further, by tagging all involved processes appropriately, multiple consensus based problems can be dealt with on a set of consensus server processes simultaneously.

Description:
BACKGROUND OF THE INVENTION 
     The present invention relates generally to computer software, and more particularly, to a system and method for a scalable, high performance computing infrastructure for distributed software applications over a computer network. 
     With the rapid expansion of both local and wide area computer networks, it is no longer an unreachable goal to link geographically distributed network sites (or nodes) together. This has led to a demand for the development of distributed software applications that take advantage of the revolutionized computing connectivity. A distributed computer system will have various software applications located on different local nodes, but are concerted to act together. Writing reliable distributed software applications for a distributed computer system has been a difficult and error-prone activity due to a variety of reasons such as asynchrony of different nodes in the distributed network, individual node or network failures, network partitioning, or uncontrollable network latencies, etc. Although each local distributed software application may be functional at the local node, maintaining a consistent global state has been enormously difficult. In the face of this complexity, programmers are forced to create centralized solutions that are rarely reusable, and have poor fault tolerance. Therefore, actual implementations of a fault tolerant, high performance distributed computer system hardly exist in the industry. 
     The design as well as the verification of a fault-tolerant distributed system is a highly non-trivial task and rests on a few fundamental paradigms. One key paradigm among these is consensus. Consensus can be viewed as a general form of agreement in the distributed computer system, wherein a group of processes reach a common decision based on their initial inputs, despite failures of some of the processes in the group. Atomic Broadcast, another important paradigm in the distributed systems, has been shown to be equivalent to consensus. Further, many frequently occurring problems such as Atomic Commitment, Group Membership and View Synchrony can be reduced to an appropriate consensus based problem. Besides the consensus issue, reliability of such a distributed computer system is also a key concern. Various applications for a distributed computer system that require a high reliability include air traffic control systems, automation software for industries, financial and brokerage software and many more. 
     A method and system is thus needed for dealing with all consensus based problems in a high performance distributed computer system that is tolerant to node or network failures and latencies. 
     SUMMARY OF THE INVENTION 
     A system and method is provided for a high performance distributed computer network system that is tolerant to node or network failures and latencies. The distributed computer system is a dynamic clustering computing system where distributed objects can join and leave a cluster as an application demands. It effectively deals with all consensus based problems in the distributed computer network having various consensus based application protocols. 
     In some embodiments, the system is a common platform supporting heterogeneous operating systems and provides structuring mechanisms to present a global state of a distributed application using an “objects as groups” paradigm. 
     In some embodiments, structuring abstraction elements such as transactional messaging and group communications are available in a distributed computer network. These embodiments thus provide a software-based approach to object clustering where distributed objects are the units for clustering together and an object group abstraction is the principal structuring element. 
     Some embodiments include an event bus for transporting all communication messages among objects or processes in the distributed computer system. These embodiments also have a fault-tolerant, client-server architecture where a client process presents a particular consensus based problem to server processes to start a consensus service in order to solve such a consensus based problem. In addition, one or more priority failure detectors may be included that detect process failures in the distributed computer network. The present invention assigns priority levels to processes involved in a consensus session and controls the frequencies of their heartbeat status messages based on their respective priority levels. By controlling the frequencies, the reliability of the network is enhanced because processes having high priority can have a high rate of message communication. On the other hand, the overall message load on the event bus can be controlled and reduced to a minimum number due to a reduction of status messages for the low priority processes. 
     Some embodiments also disclose a Name Service that assigns unique logical identities to all processes in a consensus service. In one embodiment of the present system, during the initiation of a consensus service, all participating consensus server processes are required to register with the Name Service, and logical identities will be assigned only after all participating consensus server processes complete the registration process. 
     In another embodiment, the present invention handles multiple consensus based problems concurrently. By tagging all involved processes appropriately, multiple consensus based problems can be dealt with on a set of consensus server processes simultaneously. 
     The present invention thus improves the performance and enhances the reliability of such a distributed computer network. 
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS 
     FIG. 1 illustrates a schematic of one embodiment of the present invention for a high performance distributed computer system. 
     FIG. 2 illustrates an operation of a Distributed Consensus Service of the system of FIG.  1 . 
     FIG. 3 illustrates a design of a consensus server process with a layering representation. 
    
    
     DESCRIPTION OF THE PREFERRED EMBODIMENTS 
     In a distributed computer system, a set of objects or processes that are scattered across a distributed computer network can hardly cooperate to agree upon a common value that is to be used for all of them. Once a distributed consensus based problem is dealt with, practical agreement problems such as Atomic Commitment, Atomic Broadcast, and View-Synchronous Group Membership can be solved too. Since these problems are difficult to handle in the distributed computer system, solutions to them provide powerful structuring mechanisms through which multiple distributed applications can maintain a consistent global state even in the presence of node and link failures. A common platform is thus provided for supporting heterogeneous operating systems and for providing structuring mechanisms to present a global state of a distributed application using an “objects as groups” paradigm. For the sake of explaining the present invention and as it is known in the art, the term “process” and the term “object” are used interchangeably. Also, in the following description, the term “message” and the term “event” are used interchangeably. 
     FIG. 1 is a schematic of a high performance distributed computer network system (the “System”)  10  for handling distributed applications according to one embodiment of the present invention. The System  10  is implemented using a modular architecture. An Event Bus  12  provides basic message transportation services to all components in the System  10 . Connecting and communicating to the Event Bus  12  are a pool of consensus servers labeled P 1 -P n    14 . Their major function is to solve specific consensus based problems  16  such as ap 1 -ap m  for application objects  18 , which are also labeled as app 1 -app k . Hence, the application objects  18  and the consensus servers  14  bear a client-server relationship respectively. Both the clients and the servers have access to a series of priority failure detectors  20 . A Name Service  22  provides unique logical identification numbers or IDs to each application object  18 . The Name Service is a generic service that assigns logical IDs to all processes in a Consensus Service if needed. 
     The Event Bus  12  is the back bone, or the main message communication channel of the System  10 , on which applications can exchange messages. A message can be any arbitrary object. All the messages can be easily filtered, logged, or correlated if it is necessary. The Event Bus  12  supports both unreliable messaging process such as UDP or IP multicast messaging and reliable messaging process such as TCP multicast messaging. Protocols for reliable multicast messaging are based on gossip-style anti-entropy type that are scalable and reliable for each event. That is, messages are guaranteed to be delivered if both sender and receiver objects are correctly identified. It is known that gossip-style protocol sessions are probabilistic in nature, i.e., a process chooses its partner processes with which it communicates randomly. In one embodiment of the present invention, the partner processes can be chosen a priori at when a process joins a consensus group. With the above described structure, a high reliability is achieved even in wide area networks. 
     The Event Bus  12  is also composed of a stack of protocol object layers, each of the layers providing and defining a different Quality-of-Service (QOS). Although no guarantees are provided regarding message transmission delays, the Event Bus  12  offers different QOS with respect to reliability of the transmission. For example, some processes can choose UDP protocol to send their messages if there is not much concern about the reliability of the message transmission, while some other processes having a serious concern about network communication reliability can use TCP protocol for a far better reliability performance. In the case of a reliable QOS, the Event Bus  12  can be classified as “eventually reliable,” which means that a message sent by a process to another process is eventually delivered if both of them are “live” processes. One way of achieving this would be by retransmission of messages in the case of a unicast messaging or by “gossip” in the case of a multicast messaging. 
     Hence, by choosing an appropriate QOS, application processes can implement anything from comparatively unreliable IP multicast and UDP unicast messaging to TCP or more reliable multicast messaging. Since such processes are executed through sending, receiving messages, or performing a local computation, applications need to couple transport reliability with typical messaging semantics such as push, pull, remote method call or asynchronous receive (callbacks) to implement their required messaging functionality. Thus it is important that receiver objects can subscribe for messages based on their application defined types or their contents. For application defined types, such as Java types, it means that an application can define its own type of message and subscribe for that type of message. If an incoming message is of the application defined type, then it will be delivered to the application. On the other hand, for a content based subscription, the content of a message is to be examined to find whether it will be delivered to a corresponding receiver. For instance, an application can subscribe to the messages from a Stock Exchange if the company name is Novell and the stock value is more than $50. Then a message only gets delivered if the content in the message has Novell and the stock value is over $50. 
     As shown in FIG. 1, a series of priority failure detectors  20  monitor application processes of the System  10 . Each of the priority failure detectors  20  maintains a list of application processes that are currently suspected to be inoperative and a list of application processes that are running appropriately. 
     In one embodiment of the present invention, the failure detection is implemented through a message communication mechanism called “heartbeat” messaging. For instance, an application object A periodically sends an “I am alive” status message to all other application objects. If an application object B does not receive such a message from A within a predetermined timeout period, then B&#39;s priority failure detector starts to suspect whether A is inoperative. The failure detector thus put A on its suspect list. If later B receives a message from A that indicates A&#39;s continuous and uninterrupted operation, B recognizes that the previous suspicion may not be warranted, and removes A from the suspect list. As a consequence, B also extends the predetermined timeout period for A since this experience has instructed B that the previous value for the timeout period may not work the best for indicating the status of A. 
     These heartbeat status messages are important to the System  10 , however a universal frequency of these heartbeat status messages can overload the Event Bus  12 . Thus, a method to reduce an overall number of these messages is needed. First, the System  10  prioritizes all participating processes in a consensus session according to their importance. Since processes of lower priorities can afford to send the heartbeat status messages in a less frequent manner, the System  10  adjusts the frequency accordingly so as to reduce the total number of messages on the Event Bus  12 . On the other hand, some processes are of high priority to the consensus session, thus it is important to know the status of these processes at any given time. Therefore, the frequency of the heartbeat status messages sent by a high priority process can be adjusted to a higher rate comparing to low priority processes. Consequently, the reliability of the System  10  is enhanced by raising such frequencies. On intranets and tightly-coupled clusters, the priority failure detectors  20  come close to achieving eventually perfect properties, since a failure suspicion indicates with high probability that a suspected object, or the link to it, has indeed failed. Moreover, the priority levels can be set or changed dynamically by the System  10 . Further, in another embodiment of the present invention, a regular message, in lieu of a particularly formatted heartbeat status message, can be used for the purpose of informing the priority failure detectors  20  about the “liveliness” of other processes. By doing so, the number of heartbeat status messages are further reduced. 
     In detecting node or network failures, the System  10  implements a fail-stop model, i.e., once a process fails, it never recovers. As an alternative, a more general crash-recovery model can be implemented. 
     With the Event Bus  12  and the priority failure detectors  20  in place, a Distributed Consensus Service (DCS) is provided by the System  10  to directly deal with consensus based problems and thus helps to build an efficient distributed computer network. The DCS is a generic agreement service that can be customized to solve specific instances of consensus based problems by defining various filter functions. 
     From the perspective of a system architecture, the DCS may include the consensus servers  14 , the consensus clients  18 , the priority failure detectors  20  and other necessary application processes. In one embodiment of the present invention, when an initiator, which is one of the consensus clients  18 , multicasts a message to a set of other consensus clients  18 , it thus starts a consensus based problem. The consensus client uses the consensus servers  14  to solve the consensus based problem in a consensus session. However, the client and server roles can also be overlapped, for example, the role of the server process can be played by a subset or all of the client processes. Interactions among the initiator, the consensus clients  18 , and the consensus servers  14  take place over reliable multicast messaging. In order to enhance the reliability of the System  10 , the consensus servers  14  usually retransmit messages periodically to avoid unexpected communication blockages. 
     FIG. 2 illustrates the operation of the DCS. An initiator  24  multicasts a message, which contains segments of parameters such as consensus ID, problem specific information, and selected processes for solving the consensus problem, to a selected group of consensus clients  18 . Upon receiving the initiation message, the consensus clients  18  compute certain data which contain problem specific information, and then multicast the message further to the consensus servers  14  and wait for the decision from these servers  14 . There are consensus filters  26  attached to each server  14 , which tailor the DCS to specific consensus problems. The filters  26  transform the message received by a consensus server  14  into a consensus initial value. Usually, the consensus filter  26  is defined by two parameters, a predicate function CallInitValue and a function InitValue. CallInitValue defines the condition under which InitValue can be called and a consensus session can be initiated. 
     The consensus servers  14  are required to register with the Name Service  22  every time when the DCS starts up. The consensus servers  14  are then blocked at a barrier synchronization point until all servers  14  have registered with the Name Service  22 . This helps to implement the fail-stop model where a required number of servers need to be started simultaneously. Then, the Name Service  22 , which is incorporated in the System  10  as a module, assigns unique logical IDs to each consensus server  14 , and thereafter, the consensus servers  14  begin their execution. Once it starts, no new process is allowed to join in. 
     The consensus clients  18  can also get IDs from the Name Service  22 . Each involved consensus client sends it&#39;s request to the Name Service  22 , which returns a unique identity to every consensus client  18 . After receiving all the requests, the Naming Service returns a consolidated list of all the members of the group to all the consensus clients  18 . 
     In solving a consensus based problem, usually a unanimous and irrevocable decision must be made on a value or an object that is asked for or related to that proposed by the initiator  24 . The design of a consensus server  14  can be viewed as a three-layer architecture as shown in FIG.  3 . The bottom layer  28  is a pool of consensus threads handling different consensus sessions of various consensus based problems. These are a pool of threads that execute generic consensus protocols. The middle layer  30  manages all the consensus threads, communication among various consensus servers  14 , and interactions between the Event Bus  12  and other components. The top layer  32  comprises of various specific application processes with different protocols such as atomic broadcast, atomic commit, and view synchrony, etc. The DCS is customized by appropriately defining consensus filters in a run time fashion in order to accommodate specific application processes and to solve consensus based problems. 
     As shown in FIG. 1, in a particular distributed application using a consensus based protocol, the consensus servers communicate directly with their consensus clients through the Event Bus  12 . This is depicted in FIG. 1 where the server components of the application protocols (ap 1 , ap 2  . . . ,ap k ) communicate directly with the client components (app 1 , ,app 2 , . . . appm). The consensus filters  26  for a particular application protocol receives an expected number of proposals from various clients in its group and yields its proposal to their consensus servers  14 . The consensus servers  14  decide upon one value or an object and reliably deliver it back to the consensus clients  18 . Hence, the DCS acts like a “black box” and is completely detached from the consensus clients  18  as well as their specific application protocols. This enables the DCS to work with various consensus based problems with different application protocols. This separation of a generic DCS from various application protocols makes the System  10  modular and flexible. 
     In one embodiment of the present invention, the DCS has another component that acts like a mediator among the consensus threads, the priority failure detector, the Name Service, the Event Bus  12 , and other application processes. Moreover, in order deal with multiple consensus based problems, each consensus session has a unique identification number which is tagged with all the messages that belong to the session. This assists the System  10  to handle and deliver the messages to corresponding consensus threads without confusion. 
     The DCS uses an algorithm for solving the consensus based problems. In one embodiment of the present invention, the selected algorithm uses a special type of priority failure detectors  20  which requires the number of faulty processes is less than [(n+1)/2] wherein n is the total number of processes involved. The algorithm uses a rotating coordinator paradigm and proceeds in asynchronous rounds of consensus services. During round R, a coordinator is the process number C, where C=(R mod n)+1. Once a coordinator is first selected, it tries to obtain a unanimous and consistent decision on a value or an object. All messages from the consensus clients  18  are unicasted to the “current” coordinator, but the messages from the coordinator will be multicasted to all other consensus servers  14  involved in the DCS. 
     Each round of the consensus service session is sub divided into four asynchronous phases. In phase  1 , every process sends its current estimate of the decision value to the current coordinator. The message is time-stamped with the round number. Subsequently in phase  2 , the coordinator gathers N numbers of such estimates, where N equals to (n+1)/2. Then, the coordinator selects one estimate with the largest time stamp, and multicasts it to all the processes as the new estimate. In phase  3 , a particular process has two possibilities in its operation. One, it receives the multicasted estimate from the coordinator and sends an acknowledgment to the coordinator to indicate that it adopts the estimate as its own. Or, the process, upon consulting with its priority failure detector, suspects that the coordinator has been dysfunctional, and sends a message to the coordinator indicating that it desires not to acknowledge the estimate. In phase  4 , the coordinator waits for (n+1)/2 replies, whether they are acknowledgment or non-acknowledgment messages. If all replies are acknowledgment messages, the coordinator knows that a majority of the processes have accepted the estimate, then, it multicasts a request asking every process to adopt that estimate. 
     Since all communications rely on messaging through the Even Bus  12 , it is imperative for the performance of the System to reduce messaging transfer. In one embodiment of the present invention, in order to further reduce the message traveled on the Event Bus  12 , a predetermined set of consensus clients  18  communicate only with a designated consensus server  14 . 
     In yet another embodiment of the present invention, in order to enhance the system reliability, a predetermined set of consensus clients  18  not only communicates to a primary consensus server  14 , but also communicate to a secondary consensus server  14 . Every message sent to a primary server is replicated on a secondary server. If the primary server fails for any reason, the consensus clients  18  automatically fall over to the secondary consensus server  14  after a few seconds. Since the entire state on the secondary consensus server  14  is an exact replica of the state on the primary consensus server  14 , the consensus clients  18  restart exactly where they were left off by the primary consensus server  14 . 
     In another embodiment of the present invention, the System  10  locks on two or more distributed objects using consensus based protocols in a distributed computer network. In a distributed computer system, there is no centralized lock manager and hence there will be no single point of failure. The objects who request for the lock will broadcast their requests to all resource objects of their interest. These requests are queued and processed sequentially. For each request, these resource objects undergo a consensus session and decide on an object to whom all of them will grant the lock. In one embodiment of the present invention, the lock requests are atomic-broadcasted to all the resource objects. By doing so, a new resource object can join the System  10  any time without bringing down the entire System  10 . Since it uses consensus based protocols, it is immune from failures of the resource objects. Replicated objects can also be locked along with distributed objects by implementing certain consistency conditions. 
     The above disclosure provides many different embodiments, or examples, for implementing different features of the invention. Techniques and requirements that are only specific to certain embodiments may be imported into other embodiments. Also, specific examples of components, and processes are described to help clarify the invention. These are, of course, merely examples and are not intended to limit the invention from that described in the claims. 
     While the invention has been particularly shown and described with reference to the preferred embodiment thereof, it will be understood by those skilled in the art that various changes in form and detail may be made therein without departing from the spirit and scope of the invention, as set forth in the following claims.