Startup and control of graph-based computation
25 claims: 3 independent, 22 dependent
- 1A method for executing, on a computer system, graphs expressing computations including:(a) providing at least two graph templates (310) each associated with a different computation graph (100), each computation graph (100) including a number of graph elements each associated with a corresponding computation;(b) forming at least two pools of processes, each associated with a different type of processing;and (c) processing multiple data streams concurrently, each associated with a different instance (300) of a corresponding computation graph, including for each of the data streams, forming a graph instance (300) from the graph template (310) for the corresponding computation graph (100), including allocating memory for a runtime data structure for that graph instance and copying the graph template (310) into the allocated memory, wherein each runtime data structure includes a copy of the graph template (310), a buffer section (350) which holds work elements as work elements are passed between the graph elements and queued prior to processing, and input counts for each graph element initialized to the number of inputs for that graph element, wherein each graph element of the graph instance (300) is associated with a corresponding one of the pools of processes, based on the type of processing associated with each pool of processes, wherein a first graph element is associated with a corresponding first pool of processes and a second graph element is associated with a corresponding second pool of processes, for each graph element of the graph instance (300), assigning processes from the corresponding one of the pools of processes when at least some part of all of the inputs for the graph element are available according to the initialized input counts, wherein the processes read and write work elements from and to the buffer section (350) of the runtime data structure for the graph instance (300) during processing of the data stream, and processing the data stream with the graph instance (300), including performing the computations corresponding to the graph elements of such graph instance (300) using the assigned processes;wherein steps (a) and (b) are performed prior to step (c).
- 25A system for executing, on a computer system, graphs expressing computations including:at least two graph templates (310) stored in data storage each associated with a different type of graph-based computation, each template (310) comprising a number of graph elements each associated with a corresponding computation;means for forming at least two pools of processes, each associated with a different type of processing;and means for processing multiple data streams concurrently, each associated with a different instance (300) of a corresponding graph-based computation, including for each of the data streams, forming a graph instance (300) from the graph template (310) associated with the corresponding type of graph-based computation, said graph instance (300) having graph elements corresponding to the graph elements of the graph template (310), including allocating memory for a runtime data structure for that graph instance and copying the graph template (310) into the allocated memory, wherein each runtime data structure includes a copy of the graph template (310), a buffer section (350) which holds work elements as work elements are passed between the graph elements and queued prior to processing, and input counts for each graph element initialized to the number of inputs for that graph element, wherein each graph element of the graph instance (300) is associated with a corresponding one of the pools of processes, based on the type of processing associated with each pool of processes, wherein a first graph element is associated with a corresponding first pool of processes and a second graph element is associated with a corresponding second pool of processes, for each graph element of the graph instance (300), assigning processes from the corresponding one of the pools of processes when at least some part of all of the inputs for the graph element are available according to the initialized input counts, wherein the processes read and write work elements from and to the buffer section (350) of the runtime data structure for the graph instance (300) during processing of the data stream, and processing the data stream with the graph instance (300), including performing computations corresponding to the graph elements of such graph instance using the assigned processes;wherein the system is configured to form the at least two pools of processes prior to processing the multiple data streams concurrently, each associated with a different instance (300) of a corresponding graph-based computation.
Independent claims3
100 paragraphs, as filed
Background
This invention relates to execution of graph-based computations.
Complex computations can often be expressed as a data flow through a directed graph, with components of the computation being associated with the vertices of the graph and data flows between the components corresponding to links (arcs, edges) of the graph. A system that implements such graph-based computations is described in <patcit id="pcit0001" dnum="US5966072A"><text>US Patent 5,966,072</text></patcit> EXECUTING COMPUTATIONS EXPRESSED AS GRAPHS. One approach to executing a graph-based computation is to execute a number of processes, each associated with a different vertex of the graph, and to establish communication paths between the processes according to the links of the graph. For example, the communication paths can use TCP/IP or UNIX domain sockets, or use shared memory to pass data between the processes.
<nplcit id="ncit0001" npl-type="b"><text>Babaoglu O et al: Mapping parallel computations onto distributed systems in paralex Compeuro 91. Advanced computer technology, reliable systems and applications 5th Annual European conference proceedings, Bologna, Italy, 13-16 May 1991, Los Alamitos, CA, USA, IEE computing society, US, 13 May 1991 (1991-05-13) pages 123-130 XP010022845 ISBN: 0-8186-2141-9</text></nplcit>, describes executing a paralex program.
Summary of Invention
The invention is defined in the independent claims to which reference is now directed.
In a general aspect of the invention, a method for efficient startup of a graph-based computation involves precomputing data representing a runtime structure of a computation graph such that an instance of the computation graph is formed using the precomputed data for the required type of graph to form the runtime data structure for the instance of the computation graph.
In another general aspect of the invention, a method for efficient control of graph-based computation involves forming pools of processes that are each suitable for performing computations associated with one or more vertices of the computation graphs. At runtime, members of these pools of processes are dynamically assigned to particular vertices of instances of computation graphs when inputs are available for processing at those vertices.
Another general aspect of the invention involves a combination of the efficient startup and process pool aspects.
Embodiments of the invention may include one or more of the following features: <ul id="ul0001" list-style="none" compact="compact"><li>The graph elements can include vertices or links of the computation graph.</li></ul>
Providing the one or more graph templates can include storing the templates in volatile memory or in non-volatile memory.
The graph instance can be formed from the graph template in volatile memory.
Forming the graph instance can include allocating a portion of the memory to the graph instance and copying the graph template to that portion of the memory.
Processes can be assigned dynamically for part of the computation on the data stream.
Processes can be assigned when at least some part of all of the inputs for such part of the computation are available.
Processes can be assigned when all of the inputs for such part of the computation are available.
Assigning each of the processes dynamically can include deassigning the process from the graph element.
Each of the processes for a graph element can be assigned for processing all of the data stream.
The method can further include releasing the processes assigned to graph elements and destroying the instance of the graph.
At least two data streams each associated with a different computation graph can be processed concurrently.
At least one graph element of instances of each of different computation graphs can be associated with a same corresponding pool of computation processes.
At least one process of a same corresponding pool of processes can be assigned at different times to a graph element of instances of different computation graphs.
In another aspect, in general, the invention features software, stored on a computer-readable medium, for processing graph-based computations.
In another aspect, in general, the invention features a system for processing graph-based computations.
Aspects of the invention can include one or more of the following advantages: <ul id="ul0002" list-style="none" compact="compact"><li>The computational overhead associated with creating instances of computation graphs is reduced as compared to establishing separate communication paths between vertices at the time the graphs are instantiated.</li></ul>
In one embodiment, use of shared memory provides an efficient communication channel for passing data between processes implementing computations for the vertices of the computation graph.
Process pools reduce the overhead associated with creating arid initialising processes for performing the computations associated with vertices of a computation graph.
Use of a dynamically assigned pools of processes reduces the resources that might otherwise be used by processes waiting for input.
Other features and advantages of the invention are apparent from the following description, and from the claims.
Description of Drawings
<ul id="ul0003" list-style="none"><li><figref idref="f0001">FIG. <b>1</b></figref> is a diagram that illustrates an instance of graph-based computation.</li><li><figref idref="f0002">FIG. <b>2</b></figref> is a logical block diagram of a system for processing work flows.</li><li><figref idref="f0003">FIG. <b>3</b></figref> is one embodiment of a data structure for a graph instance.</li><li><figref idref="f0004">FIG. <b>4</b></figref> is a data structure for the computation graph shown in <figref idref="f0001">FIG. 1</figref>.</li><li><figref idref="f0005">FIG. <b>5</b></figref> is a flowchart for system initialization.</li><li><figref idref="f0005">FIG. <b>6</b></figref> is a flowchart for processing each work flow.</li><li><figref idref="f0006">FIG. <b>7</b></figref> is a flowchart for execution of an instance of a computation graph.</li><li><figref idref="f0007">FIG. <b>8</b></figref> is a flowchart for completion of processing for a vertex.</li></ul>
Description
1.
Overview
The system described below implements a method for executing computations that are defined in terms of computation graphs. Referring to <figref idref="f0001">FIG. <b>1</b></figref>, an example of a computation graph <b>100</b> includes a number of vertices <b>110</b> that are joined by unidirectional links <b>120</b>. In the example shown in <figref idref="f0001">FIG. <b>1</b></figref>, vertices <b>110</b> are numbered from <b>1</b> to <b>6</b>, and links <b>120</b> are also numbered from 1 to 6. Computation graph <b>100</b> processes a work flow that is made up of a series of work elements <b>130</b>, such as individual transactions that are processed according to a computation graph associated with a transaction processing system. Each vertex is associated with a portion of the computation defined by the overall computation graph. In this example, vertex 1 <b>provides</b> access to storage for an initial series of work elements <b>130</b>, and passes that series on its output link 1. Processes that implement the computation associated with each of the vertices process the work elements <b>130</b> in turn, and typically produce a work element on one or more of the output links of that vertex.
As illustrated in <figref idref="f0001">FIG. <b>1</b></figref>, a work element <b>130</b> is in transit on link 1, a work element is queued ready for processing at vertex 3, and two work elements are queued for processing at vertex 4. Therefore, the processes for vertex 3 and vertex 4 are ready to run to process a queued work element. As illustrated, vertex 5 has a work element queued on one of its inputs, link 4, but not on the other input, link 5. Therefore the process associated with vertex 5 is not ready to run.
Referring to <figref idref="f0002">FIG. <b>2</b></figref>, a system <b>200</b> for processing work flows includes stored graph data structures <b>210</b>. These data structures include specifications of computation graphs that include characteristics of the vertices and links of the graphs. A graph execution and control ("GEC") module <b>220</b> of the system receives control inputs <b>222</b> including commands to process particular work flows <b>232</b> using corresponding computation graphs, which are specified in the stored graph data structures <b>210</b>. The GEC module <b>220</b> uses the specifications of the computation graphs to control graph computation processing <b>230</b>, which is generally made up of multiple processes. The processes that implement graph computation processing <b>230</b> can make use of external data and processes <b>240</b>, which include database engines, data storage, or other modules that are accessed during processing associated with vertices of the computation graphs.
In general, different types of work flows are processed using different types of computation graphs <b>100</b>, and different work flows may be processed concurrently, each being processed by a different instance of a graph. System <b>200</b>, through the GEC module <b>220</b>, allocates resources for the instances of computation graphs and controls their execution to process the work flows.
2.
Graph data structures
System <b>200</b> includes a number of features that provide rapid startup of graph computations as well as efficient sharing of limited resources.
Before processing a work flow with an instance of a computation graph, the GEC module <b>220</b> creates a runtime data structure for that graph instance in a functionally shared memory. In one embodiment, a single shared memory segment is created in which all the runtime data structures for graph instances are created.
Processes are associated at runtime with the vertices of the graph and each of these processes maps the shared memory segment into their address space. The processes read and write work elements from and to the runtime data structures for the graph instances during processing of the work flows. That is, data for the work elements that flow through the graph are passed from process to process through this runtime data structures in the shared memory segment.
Graph computation processing <b>230</b> may be hosted on a general-purpose computer under the control of a suitable operating system, such as the UNIX operating system. The shared memory for an instance of the graph preferably is accessible using standard system services (<i>e.g</i>., the mmap() UNIX system service) that provide memory mapping functions to mapped the shared memory segment holding the runtime graph data structures into the address spaces of the processes implementing the computation graph.
<figref idref="f0003">FIG. <b>3</b></figref> is one embodiment of a runtime graph data structure <b>300</b> for an instance of a computation graph. A header section <b>320</b> includes the number of vertices <b>322</b> and the number of links <b>324</b> of the graph. Runtime graph data structure <b>300</b> also includes a vertex section <b>330</b> that specifies the vertices of the graph in a series of records <b>332</b>, each associated with a different vertex. The runtime structure also includes a link section <b>340</b>, which includes link records <b>342</b> each specifying a different link of the graph. Runtime graph data structure <b>300</b> also includes a buffer section <b>350</b>, which holds work element data as the work elements are passed between vertices of the computation graph and queued prior to processing at a vertex.
In vertex section <b>330</b>, each vertex record <b>332</b> typically includes data that identifies the input links <b>334</b> for the corresponding vertex and the output links <b>335</b> for the vertex. For example, the links and the vertices may be numbered consecutively from <b>1</b>, and the input and output link data for a vertex may be represented as a list of indices including those links.
In this example, each vertex record <b>332</b> also includes storage for an input count <b>336</b> that indicates the number of inputs that do <i>not</i> have a work element queued and waiting for processing. During execution of the graph, this variable is initialized to the number of input links for the vertex, is decremented as input becomes available on each input for a vertex, incremented when an input queue is empties, and reaches zero when there is an input available on each input and the process for that vertex is ready to run.
In this example, each vertex record <b>332</b> also includes a process pool identification <b>337</b> that specifies a pool of processes associated with that vertex (a further discussion of process pools is included later in this description). Processes in the identified pool are used to perform the processing for that vertex. In general, the processing for a vertex can be performed by any member of the identified pool. Processes are dynamically allocated for each work element and therefore different work elements that are processed by the same vertex in an instance of a computation graph may be processed by different members of the identified pool. Vertex record <b>332</b> optionally includes configuration data <b>338</b> that is used to tailor any member process of the identified pool to perform the particular processing for that vertex.
Link section <b>340</b> of runtime graph data structure <b>300</b> specifies the links of the graph in link records <b>342</b>. Each link record <b>342</b> may include data that identifies the source vertex <b>346</b> for that link and the destination vertex <b>347</b> for the links. Each link record optionally includes configuration data <b>345</b> that is used when the runtime data structure is created.
Buffer section <b>350</b> of runtime graph data structure <b>300</b> includes a number of separate buffer areas <b>352</b> associated with the links of the graph. Each link record <b>342</b> typically includes a buffer location <b>344</b> that identifies a corresponding buffer area <b>352</b> for that link record. Each buffer area typically includes a FIFO queue <b>360</b> that holds a number of work elements <b>362</b> that have not yet been processed by the destination vertex of the corresponding link.
Referring to <figref idref="f0004">FIG. <b>4</b></figref>, a runtime graph data structure <b>300</b> for the example of a computation graph <b>100</b> shown in <figref idref="f0001">FIG. <b>1</b></figref> indicates that there are 6 vertices and 6 links in the header. Vertex section <b>340</b> has six vertex records <b>332</b>. For example, the vertex record <b>332</b> for vertex 1 indicates in entry <b>334</b> that there are no input links and in entry <b>335</b> that link 1 is an output link. The vertex record <b>332</b> for vertex 2 indicates that link 1 is an input link and that links 2 and 3 are output links. As illustrated in <figref idref="f0001">FIG. <b>1</b></figref>, a work element for vertex 2 is not queued ready for processing, and therefore the input count <b>336</b> of the vertex record indicates that there is still one unsatisfied input.
Link section <b>350</b> includes six link records <b>340</b>, one for each of the links of the computation graph. For example, the link record <b>342 for</b> link 1 has an entry <b>346</b> that indicates that the source vertex is vertex 1 and an entry <b>347</b> that indicates that the destination vertex is entry 2. An entry <b>344</b> of link record <b>342</b> provides a way of accessing the corresponding buffer record <b>352</b> of buffer section <b>350</b> (for example, according to a byte offset in the graph data structure). Each buffer record <b>352</b> includes a FIFO queue <b>360</b>. Each FIFO queue <b>360</b> can hold data for a number of work elements <b>362</b>. In correspondence with the example shown in <figref idref="f0001">FIG. <b>1</b></figref>, FIFO queues <b>360</b> for links 2 and 4 hold one work element, FIFO queue <b>360</b> for link 3 holds two work elements, and the remaining queues are empty.
Referring back to <figref idref="f0003">FIG. <b>3</b></figref>, one portion of runtime graph data structure <b>300</b> is a template <b>310</b> that is common to all instances of the same type of graph. With the exception of input count <b>336</b> of each vertex record <b>332</b>, the template portion of the runtime data structure is static. Input counts <b>336</b> for the vertices are initialized to a common value for all instances of the same type of graph: the number of inputs for the corresponding vertex, indicating that none of the inputs for the vertex are initially satisfied.
The template <b>310</b> for each type of computation graph is precomputed before runtime data structures for instances of that type of graph are needed. Creating a runtime instance then essentially involves allocating memory for the entire runtime data structure <b>300</b> and copying the appropriate template <b>310</b> into the allocated memory (depending on the structure of FIFO queues <b>360</b>, some minimal initialization of buffer section <b>350</b> may be required).
3.
Process pools
As introduced above, computation for vertices is implemented using process pools. For each of a number of different types of vertex computation, a pool of processes is created prior to beginning processing of work flows using computation graphs requiring that type of computation. During processing of a work flow by a graph instance, when computation of a particular type is needed to perform the computation for a vertex of the graph, a member of the process pool is dynamically associated with that vertex and remains associated with that vertex for the duration of processing of the work flow. There are generally many different pools of processes, each associated with a corresponding type of processing. Processes in one pool may be used for vertices in different graphs types, in different instances of one graph type, and for multiple different vertices in one graph type.
Each process in a process pool is a separate process (<i>e</i>.<i>g</i>., a UNIX process) that is invoked by the GEC module <b>220</b>, which manages the process pools. The GEC module <b>220</b> maintains a separate work queue for each process pool. Each entry in a work queue identifies a specific vertex of a graph instance for which the process is to perform computation.
In the illustrated embodiment, when a process in a pool is first created, it performs an initialization procedure which includes mapping the shared memory segment for the graph instances into the address space of the process. After the initialization procedure completes, the process waits until it is signaled by the GEC module <b>220</b> to perform the processing associated with an element in the work queue for that pool. A number of alternative mechanisms can be used to signal the process. In one version of the system, the GEC module <b>220</b> maintains a separate control channel for passing control information between it and each process in the pool. Each pool process "blocks" while waiting for input from the control process to indicate that the pool process should execute.
Some process pools are made up of processes that reserve or consume fixed resources. An example of such a pool of processes is made up of multiple instances of a process that makes a connection to a database, such as an Oracle<sup><u>®</u></sup> database. Since resources are consumed with forming and maintaining each database connection, it is desirable to limit the number of such processes that are active. When a work element to be processed at a vertex requires a process for accessing the database, one of the processes of the pool (which has already established its connection with the database) is associated with that vertex. In this way, the overhead of starting the process is avoided, as are the initialization steps of that process that would have been required to connect to that database.
System <b>200</b> supports different approaches to configuring processes for vertices, which differ in when the vertices are associated with pool processes and when the computation for the vertices is initiated. In one type of configuration, a process is not associated with a vertex until all the data at all its input work elements are completely available. If a work element is large, it may take some time for the entire work element to be computed by the upstream vertex and to be available. This type of configuration avoids blocking the process waiting for input to become available.
Another type of configuration uses a streaming mode. A process is associated with a vertex and initiated when at least the start of each input is available. The remainder of each of its inputs becomes available while the process executes. If that input becomes available sufficiently quickly, the process does not block waiting for input. However, if the inputs do not become available, the process may block.
Another type of configuration uses a disk buffering mode in which a data flow is explicitly identified as being buffered on a disk or other storage device. For example, an upstream process writes its outputs to a disk and the downstream process is only notified when that entire input is available to be read from the disk. For such a data flow, entry <b>362</b> in the corresponding FIFO queue <b>360</b> identifies the location of the data on the disk rather than holding the data directly in the FIFO queue. This configuration conserves the shared memory segment that holds FIFO queues since a disk is used rather than using memory space buffer for inputs and outputs.
There are also various degrees of specificity of the pools of processes. One type of pool is made up of processes that are very tailored to a particular vertex of particular type of graph. In another type of pool, the processes are more generic and applicable to a number of different vertices. Such processes are customized at the time that they are associated with a particular vertex. For example, the processes in a pool may be made up of data translator processes, which are generic to a number of different kinds of translation. Configuration data <b>338</b> associated with a particular vertex provides information that is used to configure the translator for that particular vertex.
When a process is signaled to process an entry in the work queue for its pool, the process acts on any configuration data <b>338</b> before processing the work elements. The process accesses the configuration data by first identifying the vertex the processing is associated with, and then accessing the corresponding vertex record <b>332</b> in the shared memory segment to find the configuration data <b>338</b>. The process then locates work elements <b>362</b> to process in the FIFO queues <b>360</b> for the input links for the vertex, and when complete, writes data to the FIFO queues for the vertex's output links.
4.
Computation control
Referring to <figref idref="f0005 f0006 f0007">FIGS. <b>5</b> to <b>8</b></figref>, system <b>200</b> uses an event-driven control approach that is coordinated by the GEC module <b>220</b>.
<figref idref="f0005">FIG. <b>5</b></figref> is a flowchart for system initialization. The GEC module <b>220</b> first creates the process pools and their associated work queues (step <b>510</b>). As part of this step, the GEC module <b>220</b> creates a separate work queue for each process pool. Next, the GEC module <b>220</b> creates a graph template <b>310</b> in its address space for each type of computation graph that may need to process a work flow, and creates a shared memory segment in which the runtime data structures for the graph instances will be created (step <b>520</b>).
<figref idref="f0005">FIG. <b>6</b></figref> is a flowchart for processing each work flow. When the GEC module <b>220</b> receives a request to process a work flow, it first creates a graph instance of the type of computation graph needed to process that work flow (step <b>610</b>). As part of this process, the GEC module <b>220</b> allocates a portion of the shared memory segment for the runtime data structure <b>300</b> for the graph instance, and copies the graph template <b>310</b> for that type of computation graph into runtime data structure <b>300</b>, thereby initializing the runtime data structure. The GEC module <b>220</b> then executes the graph instance (step <b>620</b>), as described below. When the entire work flow has been processed, the GEC module <b>220</b> preferably releases the assigned resources and deletes the runtime data structure for the graph instance, thus permitting that portion of the shared memory segment to be reused for other graph instances (step <b>630</b>).
<figref idref="f0006">FIG. <b>7</b></figref> is a flowchart for execution of an instance of a computation graph. Execution of a graph instance (see <figref idref="f0005">FIG. <b>6</b></figref>, step <b>620</b>) involves first scanning the vertices of the graph to determine whether any are initialized to have an input count of zero, which indicates that they do not require an input on any flow before executing (step <b>710</b>). The vertices with zero input counts are runnable and are added to the work queues for their associated process pools (step <b>712</b>). Because the first vertex in this example does not have any input links, it is ready to run when execution of the graph instance begins and is put in a work queue. If there are any processes in the process pools that is available to run the computation for these vertices (step <b>720</b>), then the GEC module <b>220</b> assigns that computing resource to the graph instance, immediately signals that process to run the computation, and de-queues the entry from the work queue (step <b>730</b>). If no process is available from the pools, the initially runnable vertices remain in the work queues until a later time when a process in a pool completes running its computation for a vertex in another graph instance and becomes available.
A process in a process pool that runs the computation for a vertex dequeues the input work elements from the FIFO queues <b>360</b> for the input links, and queues the output work elements to the FIFO queues <b>360</b> for the output links of the vertex. Dequeue and enqueue of the work elements from the FIFO queues preferably maintains input counts <b>336</b> for the vertices so that runable vertices have zero values of their associated input count <b>336</b>. If at times inputs are not available for processing, the process blocks until the inputs are produced by an upstream vertex and queued in the FIFO queues. When the process completes the computation for a work flow at a vertex, it signals the GEC module <b>220</b> that it has completed. The GEC module <b>220</b> can then assign the process to a different vertex that is queued in the work queue for that processes pool.
<figref idref="f0007">FIG. <b>8</b></figref> is a flowchart for completion of processing for a vertex. When the GEC module <b>220</b> is signaled by a process that it has completed its processing, and is therefore available to be assigned to another vertex, the GEC module <b>220</b> first checks to see if there are any runnable vertices in any of the graph instances (step <b>810</b>). As noted above, a runnable vertex is one for which each of its input links has a work element ready to be read, as indicated by the input count <b>336</b> being zero in the vertex record <b>332</b> for that vertex. The runnable vertices are added to the appropriate work queues for their corresponding process pools (step <b>820</b>). If there are any processes available to run computations for vertices in the work queues (step <b>830</b>), then all such processes are signaled to run the computations for the runnable vertices (step <b>840</b>).
Finally, any graph instance for which there are no longer any runnable vertices has completed processing of its work flow, and the GEC module <b>220</b> completes the execution of that graph instance (step <b>850</b>), resulting in the graph instance being removed (see <figref idref="f0005">FIG. <b>6</b></figref>, step <b>630</b>).
The computation control described above supports a number of different work flow approaches. For example, a work flow may be associated with a single transaction, and vertices process at most one work element for each of the input links and produce zero or one work elements on their outputs. A work flow can also be associated with a stream of work elements, for example, for processing an entire batch of transactions. In such a case, each vertex processes a stream of inputs and produces zero or one output for each set of its inputs.
In order for a vertex to detect that it will not receive any more inputs, as opposed to its inputs not yet being available, each upstream vertex optionally sends an explicit terminator on its downstream links. These terminators are queued and affect the input count in the same way as work elements. Therefore, when a vertex has a terminator at each of its inputs, it outputs a terminator on each of its outputs before completing its processing. By using such terminators, a process that implements a process does not have to be preconfigured to process single transactions or streams of transactions.
5.
Alternatives
In the approach to computation control described above, after a process from a process pool is assigned to a vertex in a graph instance, it is free to execute until it has completed processing of work elements in the work flow. An alternative is to limit the amount of processing at a vertex, for example, according to the amount of unprocessed output it has produced, the amount of input it has produced, or according to a processing time.
Another alternative is to relax the requirement that a process is assigned to a vertex from the time that the vertex is runnable until the vertex has completed processing of the work flow. If the vertex does not have to maintain state between processing of successive work elements in a stream of work elements for a work flow, then the process can be returned to the pool after processing a number of work elements, for example, after processing a single work element. Therefore, the same processes can then be used to perform the processing of multiple different vertices even in the same graph instance. If a process must maintain state between processing of work elements in a stream, such state can be separately maintained for the vertex and reloaded into a process when it is assigned to a vertex.
A number of optimizations of the computation control can be used. In a first optimization, propagation of work flow terminators through a graph instance avoids associating processes with vertices if all the inputs are terminators. The terminators on the inputs are dequeued, and a terminator is enqueued on each output. In another optimization, a process that completes processing for a vertex can check to see whether it is suitable for processing a downstream vertex, and then associate itself with that vertex, thereby avoiding the need to return itself to a process pool and then be reassigned to a vertex.
As another alternative, the number of processes in a process pool is optionally allowed to grow and shrink. For example, one option is that there is a minimum number of members of a pool. Depending on demand for that pool, additional members in the pool are created, followed by a gradual removal of those members as the pool processes become idle. Another option is to use a schedule for determining the number of members in a pool. For example, there may be more need for more members at different times of day. For instance, if the system is processing live transactions, a certain type of transaction may be more likely at one time of day than at another time of day.
As an alternative to, or in addition to, using "heavyweight" processes as member of process pools, a pool can be made up of a different type of process. For example, one type of alternative pool may use a single UNIX process for the pool as a whole, but the member "processes" may be lightweight threads that are pre-created and ready to run.
Another alternative is to pre-create graph pools of already instantiated computation graphs in anticipation of there being work flows that will require them. When a work flow needs a graph instance, if one is available from a graph pool, it is assigned from the pool rather than having to be created. In this way, the startup cost for a work flow is further reduced. When the computation for the work flow is completed, the graph is reset by restoring variables to their initial values prior to having been assigned to the work flow (for example, resetting input counts <b>336</b>) and freeing any dynamically-assigned memory. After the graph is reset it is returned to the pool.
As with the process pools, the number of graph instances in a graph pool can be allowed to grow as needed. For instance, there might be a minimum number of instances in each graph, and more may be created as needed.
In some alternative versions of the system, a work queue for each process pool is not necessary. For instance, whenever a member pool process is ready to take on a new task, the GEC module <b>220</b> can scan through every instance of every vertex in each graph instance to see whether there is an appropriate process to take on that work. Other alternatives include us of data structures other than work queues to identify runnable vertices. For example, a hash table can be used to identify the vertices that can be run.
In the description above, pool processes may be assigned to vertices in the graph in an on-demand manner where they are not associated with a vertex until after all the inputs to that vertex are available. Another approach is to associate the processes to the vertices when the work flow is associated with the graph instance and to maintain the association until the entire work flow has been processed.
As described above, the runtime data structure defines an entire computation graph. In alternative versions of the system, the approach described above can be combined with more traditional approaches for communicating between vertices in a computation graph. For example, a separate runtime data structure can be associated with different subgraphs of the graph. Different subgraphs can then be executed on processors that do not share memory, and communication between vertices on different processors can use communication approaches such as sockets.
The approach described above can be extended to other graph specifications. For example, a hierarchical specification of a computation graph can be implemented by assembling a graph instance from templates for the various nested computation graphs.
As described above, the GEC module <b>220</b> computes and stores graph templates in working memory. As an alternative, these graph templates can be stored in external memory, such as on magnetic disks. As another alternative, the graph templates are not necessarily memory images that are reproduced to form a graph instances. For example, a graph template can include a compressed or symbolic representation that is used to form a corresponding graph instance.
In general, various alternative forms of memory sharing can be used, for instance, depending on the operating system used.
6.
Applications
One application of computation graphs of the type described above is for processing financial transactions in a banking application. In general, different types of transactions require different types of computation graphs. A typical computation graph is associated with some combination of a type of customer transaction and "backend" services that are needed to process the transaction. For example, transactions can be ATM requests, bank teller inputs, and business-to-business transactions between computers or web servers. Different customers might have different backend systems, particularly when banks consolidate and customers are combined from different original banks. Their accounts may be maintained on very different backend systems even though they are all customers of the acquiring bank. Therefore, different vertices in a graph may be used to process different transactions. Different services may be associated with vertices in the graph. For instance, some of the vertices may be associated with functions such as updating a balance, depositing money in an account, or performing an account hold so funds are held in an account. In accordance with the invention, on-the-fly assignment of processes to vertices avoids the overhead of having processes for unused vertices remain idle.
7.
Implementation
The invention may be implemented in hardware or software, or a combination of both (<i>e</i>.<i>g</i>., programmable logic arrays). Unless otherwise specified, the algorithms included as part of the invention are not inherently related to any particular computer or other apparatus. In particular, various general purpose machines may be used with programs written in accordance with the teachings herein, or it may be more convenient to construct more specialized apparatus (<i>e.g</i>., integrated circuits) to perform particular functions. Thus, the invention may be implemented in one or more computer programs executing on one or more programmed or programmable computer systems (which may be of various architectures such as distributed, client/server, or grid) each comprising at least one processor, at least one data storage system (including volatile and non-volatile memory and/or storage elements), at least one input device or port, and at least one output device or port. Program code is applied to input data to perform the functions described herein and generate output information. The output information is applied to one or more output devices, in known fashion.
Each such program may be implemented in any desired computer language (including machine, assembly, or high level procedural, logical, or object oriented programming languages) to communicate with a computer system. In any case, the language may be a compiled or interpreted language.
Each such computer program is preferably stored on or downloaded to a storage media or device (<i>e.g</i>., solid state memory or media, or magnetic or optical media) readable by a general or special purpose programmable computer, for configuring and operating the computer when the storage media or device is read by the computer system to perform the procedures described herein. The inventive system may also be considered to be implemented as a computer-readable storage medium, configured with a computer program, where the storage medium so configured causes a computer system to operate in a specific and predefined manner to perform the functions described herein.
It is to be understood that the foregoing description is intended to illustrate and not to limit the scope of the invention, which is defined by the scope of the appended claims. Other embodiments are within the scope of the following claims.
7 sheets
Sheet 1 Sheet 2 Sheet 3 Sheet 4 Sheet 5 Sheet 6 Sheet 7
Every citation, both waysCites: the store holds 4 of 5
| Document | Relation | Office |
|---|---|---|
| US5966072A | Cites | United States of America |
| US6314114B1 | Cites | United States of America |
| US6654907B2 | Cites | United States of America |
| US6658464B2 | Cites | United States of America |
| BABAOGLU O ET AL: "Mapping parallel computations onto distributed systems in Paralex" COMPEURO '91. ADVANCED COMPUTER TECHNOLOGY, RELIABLE SYSTEMS AND APPLICATIONS. 5TH ANNUAL EUROPEAN COMPUTER CONFERENCE. PROCEEDINGS. BOLOGNA, ITALY 13-16 MAY 1991, LOS ALAMITOS, CA, USA,IEEE COMPUT. SOC, US, 13 May 1991 (1991-05-13), pages 123-130, XP010022845 ISBN: 0-8186-2141-9 | Non-patent | – |
| GAMMA E ET AL: "Design Patterns: Elements of Reusable Object-Oriented Software" DESIGN PATTERNS. ELEMENTS OF REUSABLE OBJECT-ORIENTED SOFTWARE, September 1999 (1999-09), XP002455565 | Non-patent | – |
20 members in 7 offices
Priority claims7
| Document | Office | Kind | Date |
|---|---|---|---|
| 268509 | United States of America | – | |
| 26850902 | United States of America | A | |
| 0332099 | United States of America | W | |
| 2003032099 | – | – | – |
| 268509 | – | – | – |
| US20020268509 | – | – | – |
| WO2003US32099 | – | – | – |
Members20
| Document | Office | Kind | |
|---|---|---|---|
| US2004073529A1 | United States of America | A1 | |
| CA2501876A1 | Canada | A1 | |
| WO2004034322A1 | World Intellectual Property Organization (WIPO) | A1 | |
| AU2003279228A1 | Australia | A1 | |
| EP1559069A1 | European Patent Office (EPO) | A1 | |
| JP2006504160A | Japan | A | |
| HK1081306A1 | Hong Kong, China | A1 | |
| US7167850B2 | United States of America | B2 | |
| US2007022077A1 | United States of America | A1 | |
| US2007179923A1 | United States of America | A1 | |
| EP1559069A4 | European Patent Office (EPO) | A4 | |
| AU2003279228B2 | Australia | B2 | |
| US7577628B2 | United States of America | B2 | |
| AU2003279228C1 | Australia | C1 | |
| US7636699B2 | United States of America | B2 | |
| JP2010244563A | Japan | A | |
| EP2284774A1 | European Patent Office (EPO) | A1 | |
| CA2501876C | Canada | C | |
| JP5475553B2 | Japan | B2 | |
| EP1559069B1This record | European Patent Office (EPO) | B1 |
72 legal events, as 9 offices reported them to INPADOC
Over the term
Point at a mark for the eventEvents
| Event | Code | Office | |
|---|---|---|---|
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Patent expired after termination of 20 yearsExpiredPE20 | PE20 | GB | |
| Expiry of rightR071 | R071 | DE | |
| Opt-out of the competence of the unified patent court (upc) registeredP01 | P01 | EP | |
| Annual fee paid to national office [announced via postgrant information from national office to epo]GrantedPGFP | PGFP | EP | |
| Annual fee paid to national office [announced via postgrant information from national office to epo]GrantedPGFP | PGFP | EP | |
| Annual fee paid to national office [announced via postgrant information from national office to epo]GrantedPGFP | PGFP | EP | |
| Fee paymentPLFP | PLFP | FR | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Fee paymentPLFP | PLFP | FR | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Fee paymentPLFP | PLFP | FR | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| No opposition filedOpposition26N | 26N | EP | |
| Standard patents granted in hong kongGrantedGR | GR | HK | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Patent lapsedLapsedMM4A | MM4A | IE | |
| No opposition filed within time limitOppositionORIGINAL CODE: 0009261PLBE | PLBE | EP | |
| Information on the status of an ep patent application or granted ep patentGrantedSTATUS: NO OPPOSITION FILED WITHIN TIME LIMITSTAA | STAA | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| No opposition filed against granted patent, or epo opposition proceedings concluded without decisionGrantedR097 | R097 | DE | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Patent ceasedCeasedPL | PL | CH | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Deletion acc. to par. 5 (withdrawal of the translation of the ep patent)MK05 | MK05 | AT | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Patent invalid in the netherlands as no translation has been filedMP | MP | NL | |
| Dpma publication of mentioned ep patent grantGrantedR096 | R096 | DE | |
| Fee paymentPLFP | PLFP | FR | |
| Reference to at number (ep patent validated in austria)REF | REF | AT | |
| European patents granted designating irelandGrantedFG4D | FG4D | IE | |
| European patent takes effect as a national patent in ch/liEP | EP | CH | |
| Designated contracting statesAK | AK | EP | |
| European patent grantedGrantedFG4D | FG4D | GB | |
| (expected) grantORIGINAL CODE: 0009210GRAA | GRAA | EP | |
| Grant fee paidORIGINAL CODE: EPIDOSNIGR3GRAS | GRAS | EP | |
| Intention to grant announcedINTG | INTG | EP | |
| Despatch of communication of intention to grant a patentORIGINAL CODE: EPIDOSNIGR1GRAP | GRAP | EP | |
| Information provided on ipc code assigned before grantRIC1 | RIC1 | EP | |
| Amendment of ipc main classPREVIOUS MAIN CLASS: G06N0005000000R079 | R079 | DE | |
| Appeal procedure closedAppealORIGINAL CODE: EPIDOSNNOA9EAPBT | APBT | EP | |
| Appeal reference modifiedAppealORIGINAL CODE: EPIDOSCREFNEAPAF | APAF | EP | |
| Date of receipt of statement of grounds of appeal recordedAppealORIGINAL CODE: EPIDOSNNOA3EAPBR | APBR | EP | |
| Appeal reference recordedAppealORIGINAL CODE: EPIDOSNREFNEAPBK | APBK | EP | |
| Date of receipt of notice of appeal recordedAppealORIGINAL CODE: EPIDOSNNOA2EAPBN | APBN | EP | |
| Party data changed (applicant data changed or rights of an application transferred)RAP1 | RAP1 | EP | |
| Party data changed (applicant data changed or rights of an application transferred)RAP1 | RAP1 | EP | |
| First examination report despatched17Q | 17Q | EP | |
| Supplementary search report drawn up and despatchedA4 | A4 | EP | |
| Requests to designate patent in hong kongDE | DE | HK | |
| Request for extension of the european patent (deleted)DAX | DAX | EP | |
| Request for examination filed17P | 17P | EP | |
| Designated contracting statesAK | AK | EP | |
| Request for extension of the european patentAX | AX | EP | |
| Public reference made under article 153(3) epc to a published international application that has entered the european phaseORIGINAL CODE: 0009012PUAI | PUAI | EP |
Numbers
- Publication
- 1559069
- Publication, DOCDB
- 1559069
- Publication, EPODOC
- EP1559069
- Application
- 37707205
- Application, DOCDB
- 03770720
- Application, EPODOC
- EP20030770720
Titles3
- German
- HERAUFFAHREN UND STEUERN GRAPH-GESTÜTZTERBERECHNUNG
- English
- STARTUP AND CONTROL OF GRAPH-BASED COMPUTATION
- French
- DEMARRAGE ET COMMANDE DE CALCUL A BASE DE GRAPHIQUE
Classification
- CPC, 2
- G06F9/50
- G06F9/4494
- IPC, 4
- G06F9 50
- G06F9 00
- G06F17 00
- G06N5 00
Designated states1
- Contracting states, 1
- Türkiye
