Multithreading with concurrency domains
First Claim
Patent Images
1. A system for synchronizing operations of components of a software application, comprising:
- a memory; and
a processor, coupled to the memory, configured to process items associated with the software application including;
a first concurrency domain that is a partition of user interface components of the software application and is for providing synchronization and thread isolation for the partitioned components, wherein the first concurrency domain includes a single internal processing thread operative to execute a single-threaded object of the software application;
a first boundary object associated with the first concurrency domain for facilitating asynchronous communications between the first concurrency domain and an external object, wherein the first boundary object is operative to;
receive a first work item from a software application object external to the first concurrency domain,determine whether at least one previously posted work item in a work item queue comprises a related task to the first work item,in response to determining that the at least one previously posted work item in a work item queue comprises a related task to the first work item, bundle the first work item with the previously posted work item in the work item queue, andin response to determining that the at least one previously posted work item in a work item queue does not comprise a related task, post the first work item to the work item queue, the first work item being directed to the single-threaded object;
a first thread dispatcher object included in the concurrency domain operative to retrieve the posted first work item from the work item queue and to pass the posted first work item to the single-threaded object for processing by the single-threaded object; and
the single-threaded object being operative to process the posted first work item and to return a result to the external object via the first boundary object such that when the first work item is to be processed in the first concurrency domain is determined by the first thread dispatcher object.
2 Assignments
0 Petitions
Accused Products
Abstract
Methods, systems and computer products are provided for partitioning software application components into separate domains called concurrency domains. Computationally expensive, slow or long-running methods may be deployed into such domains, thus keeping the associated application more responsive to the end user. According to one aspect of the invention, a given concurrency domain is a partition of runtime objects for providing synchronization and thread isolation within the partition and for providing concurrency with other such partitions in a data-driven dynamically composed and reconfigured application.
-
Citations
20 Claims
-
1. A system for synchronizing operations of components of a software application, comprising:
-
a memory; and a processor, coupled to the memory, configured to process items associated with the software application including; a first concurrency domain that is a partition of user interface components of the software application and is for providing synchronization and thread isolation for the partitioned components, wherein the first concurrency domain includes a single internal processing thread operative to execute a single-threaded object of the software application; a first boundary object associated with the first concurrency domain for facilitating asynchronous communications between the first concurrency domain and an external object, wherein the first boundary object is operative to; receive a first work item from a software application object external to the first concurrency domain, determine whether at least one previously posted work item in a work item queue comprises a related task to the first work item, in response to determining that the at least one previously posted work item in a work item queue comprises a related task to the first work item, bundle the first work item with the previously posted work item in the work item queue, and in response to determining that the at least one previously posted work item in a work item queue does not comprise a related task, post the first work item to the work item queue, the first work item being directed to the single-threaded object; a first thread dispatcher object included in the concurrency domain operative to retrieve the posted first work item from the work item queue and to pass the posted first work item to the single-threaded object for processing by the single-threaded object; and the single-threaded object being operative to process the posted first work item and to return a result to the external object via the first boundary object such that when the first work item is to be processed in the first concurrency domain is determined by the first thread dispatcher object. - View Dependent Claims (2, 3)
-
-
4. A method for synchronizing operations of components of a software application, comprising:
-
receiving first a work item for processing by a first software application component instantiated in a main concurrency domain that is a partition of user interface components of the software application and is for providing synchronization and thread isolation for the partitioned components, wherein an additional concurrency domain is created by the main concurrency domain to perform tasks for the software application and to publish results to the main concurrency domain; determining whether at least one previously posted work item in a work item queue comprises a related task to the first work item; in response to determining that the at least one previously posted work item in a work item queue comprises a related task to the first work item, bundle the first work item with the previously posted work item in the work item queue; in response to determining that the at least one previously posted work item in a work item queue does not comprise a related task, posting the work item in the work item queue by a boundary object of the of the main concurrency domain comprising one of;
a data connector and an object for facilitating asynchronous communications between concurrency domains;determining whether the first software application component has finished processing any previous work items passed to the first software application component for processing; if the first software application component has finished processing any previous work items passed to the first software application component for processing, retrieving the work item posted to the work item queue by a dispatcher object; and passing the retrieved work item to the first software application component for processing such that internal and external reentrancy problems are prevented. - View Dependent Claims (5, 6, 7, 8, 9, 10, 11)
-
-
12. A computer readable storage medium containing computer executable instructions which when executed by a computer perform a method of concurrently executing single-threaded and multithreaded objects, comprising:
-
receiving a software application containing a plurality of software components operative for processing data concurrently; separating each of the software components operative for processing data concurrently into separate concurrency domains, wherein a main concurrency domain is associated with user interface components of the software application, and a secondary concurrency domain is created by the main concurrency domain to perform tasks for the software application and to publish results to the main concurrency domain; associating a boundary object with each separate concurrency domain for receiving any data calls directed to software component objects contained in the separate concurrency domains, wherein the boundary object is operative to; receive a first work item from a software application object external to the first concurrency domain, determine whether at least one previously posted work item in a work item queue associated with the boundary object comprises a related task to the first work item, in response to determining that the at least one previously posted work item in a work item queue comprises a related task to the first work item, bundle the first work item with the previously posted work item in the work item queue, and in response to determining that the at least one previously posted work item in a work item queue does not comprise a related task, post the first work item to the work item queue, the first work item being directed to the single-threaded object; and disposing a dispatcher object in each of the separate concurrency domains for presenting data calls to individual software component objects after the individual software component objects have completed processing of other data calls previously presented to the individual software component objects such that internal and external reentrancy problems are prevented. - View Dependent Claims (13, 14, 15, 16, 17, 18, 19)
-
-
20. A method for synchronizing operations of components of a software application, comprising:
-
instantiating a first software application component in a main concurrency domain separate from other components of the software application including a single internal processing thread operative to execute the first software application component; creating, by the main concurrency domain, an additional concurrency domain is to perform tasks for the software application and to publish results to the main concurrency domain; receiving a first work item for processing by the first software application component at a boundary object associated with the main concurrency domain from an external object; determining, at the boundary object, whether at least one previously posted work item in a work item queue associated with the boundary object comprises a related task to the first work item; in response to determining that the at least one previously posted work item in a work item queue comprises a related task to the first work item, bundle the first work item with the previously posted work item in the work item queue; in response to determining that the at least one previously posted work item in a work item queue does not comprise a related task, posting the work item in the work item queue by a boundary object of the of the main concurrency domain comprising one of;
a data connector and an object for facilitating asynchronous communications between concurrency domains;determining whether the first software application component has finished processing any previous work items passed to the first software application component for processing, wherein determining whether the first software application component has finished processing any previous work items passed to the first software application component for processing includes determining whether a dispatcher object provided in the main concurrency domain has been notified that results from any previous work items passed to the first software application component have been passed from the first software application component to the boundary object; if the first software application component has finished processing any previous work items passed to the first software application component for processing, retrieving the work item posted to the work item queue by the dispatcher object; passing the retrieved work item to the first software application component for processing such that internal and external reentrancy problems are prevented, wherein passing the retrieved work item to the first software application component for processing comprises causing the dispatcher object to pass the retrieved work item to the software application component for processing in response to being notified that results from any previous work items passed to the first software application component have been passed from the first software application component to the boundary object; and causing the dispatcher object to withhold from the first software application component a posted second work item directed to the first software application component until the first software application component returns a result from a processing of the retrieved work item to the first software application via the boundary object.
-
Specification