The current application hereby incorporates by reference the material in the following patent applications:
U.S. patent application No. ______, entitled “SYSTEM AND METHOD FOR PROVIDING SUPPORTING GUARANTEED MULTI-POINT DELIVERY IN A DISTRIBUTED DATA GRID,” by inventors Robert H. Lee and Gene Gleyzer, filed ______(Attorney Docket No.: ORACL-05358US0).
U.S. patent application No. ______, entitled “SYSTEM AND METHOD FOR PROVIDING PARTITION PERSISTENT STATE CONSISTENCY IN A DISTRIBUTED DATA GRID,” by inventors Robert H. Lee and Gene Gleyzer, filed ______(Attorney Docket No.: ORACL-05359US0).
U.S. patent application No. ______, entitled “SYSTEM AND METHOD FOR PROVIDING TRANSIENT PARTITION CONSISTENCY IN A DISTRIBUTED DATA GRID,” by inventors Robert H. Lee and Gene Gleyzer, filed ______(Attorney Docket No.: ORACL-05359US1).
U.S. Patent Application No. ______, entitled “SYSTEM AND METHOD FOR SUPPORTING ASYNCHRONOUS MESSAGE PROCESSING IN A DISTRIBUTED DATA GRID,” by inventor Gene Gleyzer, filed ______(Attorney Docket No.: ORACL-05360US0).
A portion of the disclosure of this patent document contains material which is subject to Copyright protection. The copyright owner has no objection to the facsimile reproduction by anyone of the patent document or the patent disclosure, as it appears in the Patent and Trademark Office patent file or records, but otherwise reserves all copyright rights whatsoever.
The present invention is generally related to computer systems, and is particularly related to a distributed data grid.
Modern computing systems, particularly those employed by larger organizations and enterprises, continue to increase in size and complexity. Particularly, in areas such as Internet applications, there is an expectation that millions of users should be able to simultaneously access that application, which effectively leads to an exponential increase in the amount of content generated and consumed by users, and transactions involving that content. Such activity also results in a corresponding increase in the number of transaction calls to databases and metadata stores, which have a limited capacity to accommodate that demand.
This is the general area that embodiments of the invention are intended to address.
Described herein are systems and methods that can support out-of-order message processing in a distributed data grid. A cluster node in the distributed data grid can receive a plurality of messages at the cluster node in the distributed data grid. The distributed data grid allows each message in the plurality of messages to determine whether it needs to be handled in a particular order on a first thread. The cluster node can dispatch one or more of said messages that do not need to be handled in the particular order on the first thread to one or more different threads.
Described herein are systems and methods that can support out-of-order message processing in a distributed data grid.
In accordance with an embodiment, as referred to herein a “distributed data grid”, “data grid cluster”, or “data grid”, is a system comprising a plurality of computer servers which work together to manage information and related operations, such as computations, within a distributed or clustered environment. The data grid cluster can be used to manage application objects and data that are shared across the servers. Preferably, a data grid cluster should have low response time, high throughput, predictable scalability, continuous availability and information reliability. As a result of these capabilities, data grid clusters are well suited for use in computational intensive, stateful middle-tier applications. Some examples of data grid clusters, e.g., the Oracle Coherence data grid cluster, can store the information in-memory to achieve higher performance, and can employ redundancy in keeping copies of that information synchronized across multiple servers, thus ensuring resiliency of the system and the availability of the data in the event of server failure. For example, the Coherence data grid provides replicated and distributed (partitioned) data management and caching services on top of a reliable, highly scalable peer-to-peer clustering protocol.
An in-memory data grid can provide the data storage and management capabilities by distributing data over a number of servers working together. The data grid can be middleware that runs in the same tier as an application server or within an application server. It can provide management and processing of data and can also push the processing to where the data is located in the grid. In addition, the in-memory data grid can eliminate single points of failure by automatically and transparently failing over and redistributing its clustered data management services when a server becomes inoperative or is disconnected from the network. When a new server is added, or when a failed server is restarted, it can automatically join the cluster and services can be failed back over to it, transparently redistributing the cluster load. The data grid can also include network-level fault tolerance features and transparent soft re-start capability.
In accordance with an embodiment, the functionality of a data grid cluster is based on using different cluster services. The cluster services can include root cluster services, partitioned cache services, and proxy services. Within the data grid cluster, each cluster node can participate in a number of cluster services, both in terms of providing and consuming the cluster services. Each cluster service has a service name that uniquely identifies the service within the data grid cluster, and a service type, which defines what the cluster service can do. Other than the root cluster service running on each cluster node in the data grid cluster, there may be multiple named instances of each service type. The services can be either configured by the user, or provided by the data grid cluster as a default set of services.
In accordance with an embodiment of the invention, out-of-order message processing can be supported in a distributed data grid.
There can be different types of messages in the distributed data grid 200 serving various functional purposes. For example, there can be internal messages that support various system operations within the distributed data grid 200. There can also be external request messages from different outside clients. From the messaging processing perspective, not every message may need to be processed using the implicit ordering guarantee that is provided by the underlying message transfer layer 202.
In accordance with an embodiment of the invention, the distributed data grid 200 can support message processing based on an underlying message transfer layer 202. The underlying message transfer layer 202 can implicitly guarantee that the plurality of messages are received at the cluster node 201 in a stream with a particular order. For example, the underlying message transfer layer 202 can be based on either a standard network protocol such as the Transmission Control Protocol/Internet Protocol (TCP/IP) or a proprietary network protocol such as the Oracle Coherence Tangosol Cluster Management Protocol (TCMP).
The distributed data grid 200 can separate various data grid service functionalities at each cluster node 201 from the underlying message transfer layer 202. For example, various services deployed on the cluster node 201 can handle the different types of incoming messages 210 and can provide the requested functionalities, while the underlying message transfer layer 202 can provide physical means, such as the threading models, for transferring the different types of messages.
As shown in
Thus, the single thread model can cause a bottle neck at the message processing thread 205, when there are a large amount of incoming messages. In order to alleviate the bottle neck at the message processing service thread 205, the cluster node 201 allows for pre-processing the incoming messages 210, e.g. using a pre-processor 203, before push them into the message queue 204. The pre-processor 203 can dispatch the pre-processing of the incoming messages 210 to other threads, e.g. threads A-B 206-207.
Additionally, each message 210 can specify, or be capable of determining at the runtime, whether it needs to be handled in a particular order on the message processing service thread 205 or to be pre-processed on the other threads. For example, an incoming message 210 can be pre-processed on the other threads than the message processing service thread 205, when it does not have dependencies on the processing on other messages.
Such a self-processing feature enabled in each incoming message 210 allows the processing of the incoming messages 210 to become more transparent. Also, the underlying message transfer layer 202, which can be based on a message transporting protocol, is not in the best position to determine whether each message should be handled in the message processing service thread 205 or not. Thus, the distributed data grid 200 can avoid relying on the underlying message transfer layer 202 for making such sub-optimal decisions.
In accordance with an embodiment of the invention, each message 210 can provide a callback function 211, or a software hook, in the message data structure in order to inform the underlying message transfer layer 202 whether the message 210 can be pre-processed, and/or whether it needs to be handled in the particular order on the message processing service thread 205.
Furthermore, the callback function 211 in each said message can include different application logics. Such application logics can be as simple as a hard coded flag or can be implemented in much more complex application code. The determination of whether a message is capable of being pre-processed can be performed at the runtime on a per message base.
As shown in
In accordance with an embodiment of the invention, the distributed data grid 200 can provide result messages to a client application after receiving a request from the client application and eventually processing the request. The result messages can be processed out-of-order, since the result messages are designated to the user on the client end and no particular order may be required.
Similarly, the request messages can also be processed out-of-order. A request message can be either an internal request message or an external request messages. The distributed data grid allows the processing of the incoming request messages on a message-by-message base. Additionally, when multiple concurrent request messages are received from the same client, the distributed data grid 200 may process these concurrent request messages in parallel under the assumptions that these concurrent request messages are created in parallel at the client side.
The different cluster nodes 301-303 can process the messages received. For example, the cluster node A 301 can receive a stream of messages, e.g. message stream 310, from one or more upstream nodes. Additionally, both the cluster node B 302 and the cluster node C 303 can each receive a stream of messages, e.g. message streams 311-312, from the cluster node A 301. These messages 320-322 can either being originated from the cluster node A 301 or from other upstream nodes. Furthermore, the stream of messages 311 received at the cluster node B can further include one or more messages from the cluster node C 303.
Within each message stream 310-312, the messages 320-322 can be transferred in a particular order, as it is implicitly guaranteed by the underlying transfer layer. In accordance with an embodiment of the invention, each cluster node 301-303 within the distributed data grid 300 can be configured to handle out-of-order message processing. Thus, the message pre-processing at each cluster node 301-303 can be on a message-by-message base, without a need for awareness from the underlying transfer layer.
Additionally, the same message can appear in different streams of messages 310-312, and this message can be processed differently by the different cluster nodes 301-303. For example, the cluster node B 302 and the cluster node C 303 can use different thread models to process a same result message when the cluster node B 302 has a message arrived from the cluster node C 303 before the result message.
The present invention may be conveniently implemented using one or more conventional general purpose or specialized digital computer, computing device, machine, or microprocessor, including one or more processors, memory and/or computer readable storage media programmed according to the teachings of the present disclosure. Appropriate software coding can readily be prepared by skilled programmers based on the teachings of the present disclosure, as will be apparent to those skilled in the software art.
In some embodiments, the present invention includes a computer program product which is a storage medium or computer readable medium (media) having instructions stored thereon/in which can be used to program a computer to perform any of the processes of the present invention. The storage medium can include, but is not limited to, any type of disk including floppy disks, optical discs, DVD, CD-ROMs, microdrive, and magneto-optical disks, ROMs, RAMs, EPROMs, EEPROMs, DRAMs, VRAMs, flash memory devices, magnetic or optical cards, nanosystems (including molecular memory ICs), or any type of media or device suitable for storing instructions and/or data.
The foregoing description of the present invention has been provided for the purposes of illustration and description. It is not intended to be exhaustive or to limit the invention to the precise forms disclosed. Many modifications and variations will be apparent to the practitioner skilled in the art. The embodiments were chosen and described in order to best explain the principles of the invention and its practical application, thereby enabling others skilled in the art to understand the invention for various embodiments and with various modifications that are suited to the particular use contemplated. It is intended that the scope of the invention be defined by the following claims and their equivalence.
This application claims priority on U.S. Provisional Patent Application No. 61/714,100, entitled “SYSTEM AND METHOD FOR SUPPORTING A DISTRIBUTED DATA GRID IN A MIDDLEWARE ENVIRONMENT,” by inventors Robert H. Lee, Gene Gleyzer, Charlie Helin, Mark Falco, Ballav Bihani and Jason Howes, filed Oct. 15, 2012, which application is herein incorporated by reference.
Number | Date | Country | |
---|---|---|---|
61714100 | Oct 2012 | US |