Difference between revisions of "Uno/Effort/Binary/Extend Threading-Model"

From Apache OpenOffice Wiki
< Uno
Jump to: navigation, search
m (Adapted Link to Thread (Affine) Environment.)
m (Fixed path to cppuhelper/tests/loader.)
 
(97 intermediate revisions by 2 users not shown)
Line 1: Line 1:
==Creating the UNO Threading Framework==
+
Type: [[Uno/Term/Effort|effort]]  Status: Finished  Owner: [[KR|Kay Ramme]]  Availability: URE 1.3 (SRC680_m212)
  
[mailto:Kay.Ramme@sun.com], [mailto:Kai.Sommerfeld@sun.com]
+
'''The mission of this effort is, to extend the [[Uno]] threading-model, to provide a way to design an applications [[Uno/Term/Threading-Architecture|threading-architecture]] independent of the implementations.''' This can be described as [[Uno/Term/Transparent Concurrency|'''transparent-concurrency''']] wrt the implementations.
  
Status: in progress
+
==Problem==
 +
Not everything should be required to be implemented [[Uno/Term/Thread Safe|thread-safe]]. E.g. see [http://home.pacbell.net/ouster/threads.pdf comments] from John Ousterhout regarding multi-threading. Encapsulation of [[Uno/Term/Thread Affine|thread-affinity]] should be easy.
  
'''The goal of the UNO threading framrwork is, to provide a way to design an applications threading architecture independent of the implementation.''' This can be described as '''Transparent Concurrency''', in respect to the implementations.
+
==Solution==
 
+
The extended [[Uno]] threading-model is basically going to introduce the notion of an apartment into the [[Uno]] world. An apartment in [[Uno/Term|Uno terms]] is a [[Uno/Spec/Purpose Environment|purpose environment]]. Such an environment can be seen as a dedicated part of a process, giving space for objects of the same [[Uno/Term/Object Binary Interface|Object Binary Interface (OBI)]] and the same purpose. An environment can only be entered and left via defined doors, being proxy objects representing objects outside respectively inside the environment.
The UNO Threading Framework basically is going to introduce the notion of an apartment into the UNO world. An apartment in UNO terms is a purpose environment. Such an environment can be seen as a dedicated part of a process, giving space for objects of the same ABI and the same purpose. An environment can only be entered and left via defined doors, being proxy objects representing objects outside respectively inside the apartment.
+
  
 
[[Image:UNO_Envs.jpg]]
 
[[Image:UNO_Envs.jpg]]
  
All calls from one environment to another are intercepted, references to local objects get replaced with proxies to these local objects, this operation is called "mapping" in UNO terms. An object gets "mapped" from one environment to another. Proxies already representing to be mapped objects of another environment become reused during the "mapping" operation, ensuring that an object can only be "mapped" once.
+
All calls from one [[Uno/Spec/Environment|Uno Environment]] to another are intercepted, references to local objects are replaced with proxies to these local objects, this operation is called "mapping" in Uno terms. Actually, an object gets "mapped" from one [[Uno/Spec/Environment|Uno Environment]] to another. Proxies already representing to be mapped objects of another [[Uno/Spec/Environment|Uno Environment]] become reused during the "mapping" operation, ensuring that an object can only be "mapped" once.
  
Purpose environments may be dedicated to MutExes or threads. In the sense, that a MutEx becomes acquired or a thread gets switched before a call enters an environment.  
+
[[Uno/Spec/Purpose Environment|Purpose environments]] may be dedicated to MutExes or [[Wikipedia:Thread_%28computer_science%29|threads]]. In the sense, that a MutEx becomes acquired or a [[Wikipedia:Thread_%28computer_science%29|thread]] gets switched to before a call enters an environment.
  
The following specifications and features give an overview over the UNO Threading Framework. The specifications roughly depend on each other in the order listed. For example, the Threading Models specification depends on the Implementation Environments, all pieces basically creating a stack.
+
==Time Frame==
 +
Understanding of the topic let us think, that the first changes of OOo / [[Uno]] on behalf of the extended [[Uno/Term/Threading-Model|threading-model]] were going to be integrated into one of the updates in 2006. The plan was, to implement the whole stack into the {{Uno/CWS|SRC680|utf2}} [[CWS]], which had been done, to ensure that everything worked as expected. The implementation has finally be done in the {{Uno/CWS|SRC680|bunoexttm}} [[CWS]] and is currently in QA. Expectation is, that the extended [[Uno/Binary|Binary Uno]] threading model is going to be available with OOo 2.3.
  
{| style="vertical-align:top; text-align:left; background-color:#F0F0F0;"
+
==Tasks==
|+ style="font-weight:bold; color:#FFFFFF; background-color:#00315A;" | Meta Specifications
+
{|border="1" cellspacing="0" class="wikitable"
|- style="background-color:#99CCFF; font-weight:bold;"  
+
|- style="background:#efefef;"  
| Title || Version || Changed || Type
+
! Area !! Title !! State !! [[CWS]]
 
|-
 
|-
| [[OpenOffice.org Wiki: Spec Uno Threading Model | Threading Model]] || 0.1 || 12/09/2005 || Spec
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Spec/Threading-Model|Specify Threading-Model]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Implementation Environments || 0.0 || 12/09/2005 || Spec
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Spec/Environment Stack|Specify Environment Stack]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Thread Environment || 0.0 || 12/09/2005 || Spec
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Impl/Environment Stack|Implement Environment Stack]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Mutex Environment || 0.0 || 12/09/2005 || Spec
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Test/Environment Stack|Implement Test for Environment Stack]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| [http://udk.openoffice.org/projects/uno_threading_framework/uno_env_stack.spec.txt Environment Stacks] || 0.1 || 01/20/2006 || Spec
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Spec/Cascaded Mapping|Specify Cascaded Mapping]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Mapping between Purpose Environments || 0.0 || 12/09/2005 || Spec
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Impl/Cascaded Mapping|Implement Cascaded Mapping]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Purpose Environments || 0.0 || 12/09/2005 || Spec
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Test/Cascaded Mapping|Implement Test for Cascaded Mapping]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Environment Substitution || 0.0 || 12/09/2005 || Spec
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Spec/Environment Descriptor|Specify Environment Descriptor]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Identity Mapping || 0.0 || 12/09/2005 || Spec
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Impl/Environment Descriptor|Implement Environment Descriptor]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Misc. Improvements || 0.0 || 12/09/2005 || Spec
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Test/Environment Descriptor|Implement Test for Environment Descriptor]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
|}
+
 
+
{| style="vertical-align:top; text-align:left; background-color:#F0F0F0;"
+
|+ style="font-weight:bold; color:#FFFFFF; background-color:#00315A;" | Features for Binary UNO
+
|- style="background-color:#99CCFF; font-weight:bold;"
+
| Title || Spec || % || Changed || Impl || % || Changed || Test || % || Changed
+
 
|-
 
|-
| Threading Models || [[OpenOffice.org Wiki: Spec Uno Bin Threading Model | draft]] || 80% || 01/10/2006 || [[OpenOffice.org Wiki: Impl Uno Bin Threading Model | UTF2]] || 100% || 03/06/2006 || open || 0% || 12/14/2005
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Spec/Environment Substitution|Specify Environment Substitution]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Implementation Environment || [[OpenOffice.org Wiki: Spec Uno Bin Runtime Implementation Environment | final]] || 100% || 03/06/2006 || [[OpenOffice.org Wiki: Impl Uno Bin Runtime Implementation Environment | UTF2]] || 100% || 01/24/2006
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Impl/Environment Substitution|Implement Environment Substitution]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Mutex Environment || [[OpenOffice.org Wiki: Spec Uno Bin Mutex Environment | draft]] || 80% || 01/17/2006 || [[OpenOffice.org Wiki: Impl Uno Bin Mutex Environment | UTF2]] || 100% || 02/13/2006 || [[OpenOffice.org Wiki: Test Uno Bin Mutex Environment | UTF2]] || 80% || 01/27/2006
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Test/Environment Substitution|Implement Test for Environment Substitution]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Thread Affine Environment || [[OpenOffice.org Wiki: Spec/Uno/Bin/Thread Affine Environment | draft]] || 80% || 01/17/2006 || [[OpenOffice.org Wiki: Impl Uno Bin Thread Environment | UTF2]] || 100% || 01/17/2006 || [[OpenOffice.org Wiki: Test Uno Bin Thread Environment | UTF2]] || 80% || 01/27/2006
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Spec/Thread Unsafety Bridge|Specify Thread Unsafety Bridge]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Stacked Environments || [[OpenOffice.org Wiki: Spec Uno Bin Environment Stacks | draft]] || 80% || 01/17/2006 || [[OpenOffice.org Wiki: Impl Uno Bin Stacked Environments | UTF2]] || 100% || 02/27/2006 || [[OpenOffice.org Wiki: Test Uno Bin Stacked Environments | UTF2]] || 100% || 01/27/2006
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Impl/Thread Unsafety Bridge|Implement Thread Unsafety Bridge]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Cascaded Mappings || [[OpenOffice.org Wiki: Spec Uno Bin Cascaded Mapping | final]] || 100% || 12/22/2005 || [[OpenOffice.org Wiki: Impl Uno Bin Runtime Cascaded Mappings | UTF2]] || 100% || 02/01/2006 || [[OpenOffice.org Wiki: Test Uno Bin Runtime Cascaded Mappings | UTF2]] || 100% || 01/30/2006
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Test/Thread Unsafety Bridge|Implement Test for Thread Unsafety Bridge]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Purpose Environments || [[OpenOffice.org Wiki: Spec Uno Bin Purpose Environments | draft]] || 100% || 12/21/2005 || [[OpenOffice.org Wiki: Impl Uno Bin Runtime Purpose Environments | UTF2]] || 100% || 12/21/2005 || [[OpenOffice.org Wiki: Test Uno Bin Runtime Purpose Environments | UTF2]] || 100% || 02/01/2006
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Spec/Thread Affinity Bridge|Specify Thread Affinity Bridge]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Environment Substitution || [[OpenOffice.org Wiki: Spec Uno Bin Environment Substituion| draft]] || 80% || 02/01/2006 || [[OpenOffice.org Wiki: Impl Uno Bin Runtime Environment Substitution | UTF2]] || 100% || 02/01/2006 || [[OpenOffice.org Wiki: Test Uno Bin Runtime Environment Substitution | UTF2]] || 100% || | 02/01/2006
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Impl/Thread Affinity Bridge|Implement Thread Affinity Bridge]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Identity Mapping || [[OpenOffice.org Wiki: Spec Uno Bin Identity Mapping| final]] || 100% || 12/20/2005 || [[OpenOffice.org Wiki: Impl Uno Bin Runtime Environment Identify Mapping | UTF2]] || 100% || 12/16/2005 || open || 0% || 12/14/2005
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Binary/Test/Thread Affinity Bridge|Implement Test for Thread Affinity Bridge]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| style="font-weight:bold; color:#FFFFFF; background-color:#00315A;" | New Binary UNO Tools
+
 
|- style="background-color:#99CCFF; font-weight:bold;"  
+
| [[Uno/Binary|Binary Uno]] || Adapt Component Loader to support Purpose Environments || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
| Title || Spec || % || Changed || Impl || % || Changed || Test || % || Changed
+
 
|-
 
|-
| Debug Environment || [[OpenOffice.org Wiki: Spec Uno Tools Debug Environment | draft]] || 80% || 01/23/2006 || [[OpenOffice.org Wiki: Impl Uno Bin Tools Debug Environment | UTF2]] || 100% || 01/23/2006 || [[OpenOffice.org Wiki: Test Uno Bin Tools Debug Environment | UTF2]] || 100% || 01/23/2006
+
| [[Uno/Binary|Binary Uno]] || [[Uno/Cpp/Modules/CPPUhelper/tests/Loader|Test for Component Loaders support of Purpose Environments]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| style="font-weight:bold; color:#FFFFFF; background-color:#00315A;" | New Binary UNO Testers
+
| [[Uno/Binary|Binary Uno]] || Add support for extend getImplEnv function || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
|- style="background-color:#99CCFF; font-weight:bold;"  
+
|-
| Title || Spec || % || Changed || Impl || % || Changed || Test || % || Changed
+
 
 +
| [[Uno/Binary|Binary Uno]] || Adapt currentContext retrieval to support Purpose Environments || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Environment Stack Tester || [[OpenOffice.org Wiki: Spec Uno Bin Tester Stacked Environment | draft]] || 80% || 01/27/2006 || [[OpenOffice.org Wiki: Impl Uno Bin Tester Stacked Environments | UTF2]] || 100% || 02/01/2006
+
 
 +
| [[Uno/Cpp|C++ Uno]] || Adapt bootstrapping components || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Mapping Tester || [[OpenOffice.org Wiki: Spec Uno Bin Tester Mapping | draft]] || 80% || 12/22/2005 || [[OpenOffice.org Wiki: Impl Uno Bin Tester Mapping | UTF2]] || 100% || 01/30/2006
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Test/Bootstrap|Test for bootstrapping]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Environment Tester || [[OpenOffice.org Wiki: Spec Uno Bin Tester Environment | draft]] || 80% || 12/22/2005 || [[OpenOffice.org Wiki: Impl Uno Bin Tester Environment | UTF2]] || 100% || 02/17/2006
+
 
 +
| [[Uno/Cpp|C++ Uno]] || Add Purpose Environment to C++ bridges || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| style="font-weight:bold; color:#FFFFFF; background-color:#00315A;" | Features for the Binary UNO Component Loader
+
 
|- style="background-color:#99CCFF; font-weight:bold;"  
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Spec/Threading-Model|Specify Threading-Model]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
| Title || Spec || % || Changed || Impl || % || Changed || Test || % || Changed
+
 
|-
 
|-
| Implementation Env. || [[OpenOffice.org Wiki: Spec Uno Bin Loader Implementation Environment | draft]] || 80% || 02/09/2006 || [[OpenOffice.org Wiki: Impl Uno Bin Loader Implementation Environment | UTF2]] || 100% || 02/09/2006 || [[OpenOffice.org Wiki: Test Uno Bin Loader Implementation Environment | UTF2]] || 100% || 02/09/2006
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Spec/Environment Stack|Specify Environment Stack]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Stacked Environments || [[OpenOffice.org Wiki: Spec Uno Bin Loader Stacked Environments | draft]] || 80% || 02/08/2006 || [[OpenOffice.org Wiki: Impl Uno Bin Loader Stacked Environments | UTF2]] || 100% || 02/09/2006 || [[OpenOffice.org Wiki: Test Uno Bin Loader Stacked Environments | UTF2]] || 100% || | 02/09/2006
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Impl/Environment Stack|Implement Environment Stack]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Implementation Specific Environments || [[OpenOffice.org Wiki: Spec Uno Bin Loader Implementation Specific Environments | final]] || 100% || 12/20/2005 || [[OpenOffice.org Wiki: Impl Uno Bin Loader Implementation Specific Environments | UTF2]] || 100% || 02/08/2006 || [[OpenOffice.org Wiki: Test Uno Bin Loader Implementation Specific Environments | UTF2]] || 100% || 02/09/2006
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Test/Environment Stack|Implement Test for Environment Stack]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Adapt to Misc. Improvements || || || || [[OpenOffice.org Wiki: Impl Uno Bin Loader Adapt Misc Improvements | UTF2]] || 100% || 02/08/2006
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Spec/Map Helpers|Specify Map Helpers]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Adapt to Identity Mapping || || || || [[OpenOffice.org Wiki: Impl Uno Bin Loader Adapt Identity Mapping | UTF2]] || 100% || 02/07/2006
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Impl/Map Helpers|Implement Map Helpers]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Remove Deprecated Stuff || || || || [[OpenOffice.org Wiki: Impl Uno Bin Loader Removed Deprecates | UTF2]] || 100% || 02/07/2006
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Test/Map Helpers|Implement Test for Map Helpers]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| style="font-weight:bold; color:#FFFFFF; background-color:#00315A;" | Features for C++ UNO
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Spec/Shield Helpers|Specify Shield Helpers]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
|- style="background-color:#99CCFF; font-weight:bold;"  
+
| Title || Spec || % || Changed || Impl || % || Changed || Test || % || Changed
+
 
|-
 
|-
| Shield helpers || [[OpenOffice.org Wiki: Spec Uno Cpp Shield | draft]] || 80% || 02/28/2006 || [[OpenOffice.org Wiki: Impl Uno Cpp Shield | UTF2]] || 100% || 02/28/2006 || [[OpenOffice.org Wiki: Test Uno Cpp Shield | UTF2]] || 100% || 02/28/2006
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Impl/Shield Helpers|Implement Shield Helpers]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Environment Aware Reference || [[OpenOffice.org Wiki: Spec Uno Cpp Environment Aware Reference | draft]] || 80% || 01/10/2006 || [[OpenOffice.org Wiki: Impl Uno Cpp Environment Aware Reference | UTF2]] || 100% || 02/23/2006 || [[OpenOffice.org Wiki: Test Uno Cpp Environment Aware Reference | UTF2]] || 100% || | 02/03/2006
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Test/Shield Helpers|Implement Test for Shield Helpers]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Environment Guards || [[OpenOffice.org Wiki: Spec Uno Cpp Environment Guard | draft]] || 80% || 01/10/2006 || [[OpenOffice.org Wiki: Impl Uno Cpp Environment Guard | UTF2]] || 100% || 01/11/2006 || open || 0% || 01/10/2006
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Spec/FreeReference|Specify FreeReference]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Implementation Environment || [[OpenOffice.org Wiki: Spec Uno Cpp Implementation Environment | draft]] || 80% || 02/14/2006 || [[OpenOffice.org Wiki: Impl Uno Cpp Implementation Environment | UTF2]] || 100% || 02/28/2006 || [[OpenOffice.org Wiki: Test Uno Cpp Implementation Environment | UTF2]] || 100% || | 02/17/2006
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Impl/FreeReference|Implement FreeReference]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Stacked Environments || [[OpenOffice.org Wiki: Spec Uno Cpp Stacked Environments | draft]] || 80% || 02/10/2006 || [[OpenOffice.org Wiki: Impl Uno Cpp Stacked Environments | UTF2]] || 100% || 02/10/2006 || [[OpenOffice.org Wiki: Test Uno Cpp Stacked Environments | UTF2]] || 100% || 02/10/2006
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Test/FreeReference|Implement Test for FreeReference]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Misc. Improvements || [[OpenOffice.org Wiki: Spec Uno Cpp Misc| draft]] || 80% || 12/14/2005 || [[OpenOffice.org Wiki: Impl Uno Cpp Misc| UTF2]] || 100% || 12/16/2005 || open || 0% || 12/14/2005
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Spec/Environment Guard|Specify Environment Guard]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Test Helper: Object Factory || [[OpenOffice.org Wiki: Spec Uno Cpp Testhelper Objectfactory | draft]] || 80% || 01/30/2006 || [[OpenOffice.org Wiki: Impl Uno Cpp Testhelper Objectfactory | UTF2]] || 100% || 01/31/2006
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Impl/Environment Guard|Implement Environment Guard]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Bridge: Purpose Env. Support || || || || [[OpenOffice.org Wiki: Impl Uno Cpp Bridge Purpose Environments | UTF2]] || 100% || 01/30/2006 || [[OpenOffice.org Wiki: Test Uno Cpp Bridge Purpose Environments | UTF2]] || 100% || 01/30/2006
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Test/Environment Guard|Implement Test for Environment Guard]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| Helper: Purpose Environment Implementation || [[OpenOffice.org Wiki: Spec Uno Cpp Helper Purpose Environment Implementation | draft]] || 80% || 01/23/2006 || [[OpenOffice.org Wiki: Impl Uno Cpp Helper Purpose Environment Implementation | UTF2]] || 100% || 02/14/2006 || [[OpenOffice.org Wiki: Test Uno Cpp Helper Purpose Environment Implementation | UTF2]] || 100% || 01/30/2006
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Spec/Environment Descriptor|Specify Environment Descriptor]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| style="font-weight:bold; color:#FFFFFF; background-color:#00315A;" | Features for Java UNO
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Impl/Environment Descriptor|Implement Environment Descriptor]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
|- style="background-color:#99CCFF; font-weight:bold;"  
+
| Title || Spec || % || Changed || Impl || % || Changed || Test || % || Changed
+
 
|-
 
|-
| JNI Bridge: Purpose Env. Support
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Test/Environment Descriptor|Implement Test for Environment Descriptor]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| URP Bridge: Purpose Env. Support
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Spec/Environment AntiGuard|Specify Environment AntiGuard]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|-
 
|-
| style="font-weight:bold; color:#FFFFFF; background-color:#00315A;" | Features for CLI UNO
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Impl/Environment AntiGuard|Implement Environment AntiGuard]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
|- style="background-color:#99CCFF; font-weight:bold;"  
+
| Title || Spec || % || Changed || Impl || % || Changed || Test || % || Changed
+
 
|-
 
|-
| style="font-weight:bold; color:#FFFFFF; background-color:#00315A;" | Features for remote UNO
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Test/Environment AntiGuard|Implement Test for Environment AntiGuard]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
|- style="background-color:#99CCFF; font-weight:bold;"  
+
| Title || Spec || % || Changed || Impl || % || Changed || Test || % || Changed
+
 
|-
 
|-
| Purpose Env. Support
+
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Spec/Purpose Bridge Implementation Helper|Specify Purpose Bridge Implementation Helper]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 +
|-
 +
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Impl/Purpose Bridge Implementation Helper|Implement Purpose Bridge Implementation Helper]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 +
|-
 +
| [[Uno/Cpp|C++ Uno]] || [[Uno/Cpp/Test/Purpose Bridge Implementation Helper|Test for Purpose Bridge Implementation Helper]] || style="background:lightgreen;" | 100% || {{Uno/CWS|SRC680|bunoexttm}}
 
|}
 
|}
  
Current understanding of the topic lets us think, that the changes of OOo / UNO on behalf of the Threading Framework are going to be integrated into one of the next updates, probably early in 2006.
+
==Dependencies==
 +
{|border="1" cellspacing="0" class="wikitable"
 +
|- style="background:#efefef;"
 +
! Area !! Title !! State !! [[CWS]]
 +
|-
 +
| [[Uno/Cpp|C++ Uno]] ||
 +
Misc Improvements
 +
* [[Uno/Cpp/Spec/Environment|uno::Environment]] Convenience Constructors
 +
* [[Uno/Cpp/Spec/Mapping|uno::Mapping]] Convenience Constructors
 +
|| 100% || {{Uno/CWS|SRC680|krmisc}} (SRC680_m191)
 +
|-
 +
| [[Uno/Binary|Binary Uno]] ||
 +
Preparation
 +
* enable identity mapping: getting a Uno Mapping from and to the same environment - currently the runtime does return NULL, so every client has to check for it,
 +
* cleanup the dll component loader
 +
** to use the identity mapping, and
 +
** to get rid of very outdated deprecated stuff
 +
|| 100% || {{Uno/CWS|SRC680|bunoidmap}} (SRC680_m196)
 +
|-
 +
| [[Uno/Binary|Binary Uno]] || [[Uno/Effort/Binary/Implement Environment Tester|Implement Environment Tester]] || 100% || {{Uno/CWS|SRC680|bunoexttm}}
 +
|-
 +
| [[Uno/Binary|Binary Uno]] || [[Uno/Effort/Binary/Implement Mapping Tester|Implement Mapping Tester]] || 100% || {{Uno/CWS|SRC680|bunoexttm}}
 +
|-
 +
|}
 +
 
 +
 
 +
[[Category:Effort]]
 +
[[Category:Uno]]
 +
[[Category:Uno:Binary]]
 +
[[Category:Multi-Threading]]

Latest revision as of 12:40, 20 October 2009

Type: effort Status: Finished Owner: Kay Ramme Availability: URE 1.3 (SRC680_m212)

The mission of this effort is, to extend the Uno threading-model, to provide a way to design an applications threading-architecture independent of the implementations. This can be described as transparent-concurrency wrt the implementations.

Problem

Not everything should be required to be implemented thread-safe. E.g. see comments from John Ousterhout regarding multi-threading. Encapsulation of thread-affinity should be easy.

Solution

The extended Uno threading-model is basically going to introduce the notion of an apartment into the Uno world. An apartment in Uno terms is a purpose environment. Such an environment can be seen as a dedicated part of a process, giving space for objects of the same Object Binary Interface (OBI) and the same purpose. An environment can only be entered and left via defined doors, being proxy objects representing objects outside respectively inside the environment.

UNO Envs.jpg

All calls from one Uno Environment to another are intercepted, references to local objects are replaced with proxies to these local objects, this operation is called "mapping" in Uno terms. Actually, an object gets "mapped" from one Uno Environment to another. Proxies already representing to be mapped objects of another Uno Environment become reused during the "mapping" operation, ensuring that an object can only be "mapped" once.

Purpose environments may be dedicated to MutExes or threads. In the sense, that a MutEx becomes acquired or a thread gets switched to before a call enters an environment.

Time Frame

Understanding of the topic let us think, that the first changes of OOo / Uno on behalf of the extended threading-model were going to be integrated into one of the updates in 2006. The plan was, to implement the whole stack into the utf2 CWS, which had been done, to ensure that everything worked as expected. The implementation has finally be done in the bunoexttm CWS and is currently in QA. Expectation is, that the extended Binary Uno threading model is going to be available with OOo 2.3.

Tasks

Area Title State CWS
Binary Uno Specify Threading-Model 100% bunoexttm
Binary Uno Specify Environment Stack 100% bunoexttm
Binary Uno Implement Environment Stack 100% bunoexttm
Binary Uno Implement Test for Environment Stack 100% bunoexttm
Binary Uno Specify Cascaded Mapping 100% bunoexttm
Binary Uno Implement Cascaded Mapping 100% bunoexttm
Binary Uno Implement Test for Cascaded Mapping 100% bunoexttm
Binary Uno Specify Environment Descriptor 100% bunoexttm
Binary Uno Implement Environment Descriptor 100% bunoexttm
Binary Uno Implement Test for Environment Descriptor 100% bunoexttm
Binary Uno Specify Environment Substitution 100% bunoexttm
Binary Uno Implement Environment Substitution 100% bunoexttm
Binary Uno Implement Test for Environment Substitution 100% bunoexttm
Binary Uno Specify Thread Unsafety Bridge 100% bunoexttm
Binary Uno Implement Thread Unsafety Bridge 100% bunoexttm
Binary Uno Implement Test for Thread Unsafety Bridge 100% bunoexttm
Binary Uno Specify Thread Affinity Bridge 100% bunoexttm
Binary Uno Implement Thread Affinity Bridge 100% bunoexttm
Binary Uno Implement Test for Thread Affinity Bridge 100% bunoexttm
Binary Uno Adapt Component Loader to support Purpose Environments 100% bunoexttm
Binary Uno Test for Component Loaders support of Purpose Environments 100% bunoexttm
Binary Uno Add support for extend getImplEnv function 100% bunoexttm
Binary Uno Adapt currentContext retrieval to support Purpose Environments 100% bunoexttm
C++ Uno Adapt bootstrapping components 100% bunoexttm
C++ Uno Test for bootstrapping 100% bunoexttm
C++ Uno Add Purpose Environment to C++ bridges 100% bunoexttm
C++ Uno Specify Threading-Model 100% bunoexttm
C++ Uno Specify Environment Stack 100% bunoexttm
C++ Uno Implement Environment Stack 100% bunoexttm
C++ Uno Implement Test for Environment Stack 100% bunoexttm
C++ Uno Specify Map Helpers 100% bunoexttm
C++ Uno Implement Map Helpers 100% bunoexttm
C++ Uno Implement Test for Map Helpers 100% bunoexttm
C++ Uno Specify Shield Helpers 100% bunoexttm
C++ Uno Implement Shield Helpers 100% bunoexttm
C++ Uno Implement Test for Shield Helpers 100% bunoexttm
C++ Uno Specify FreeReference 100% bunoexttm
C++ Uno Implement FreeReference 100% bunoexttm
C++ Uno Implement Test for FreeReference 100% bunoexttm
C++ Uno Specify Environment Guard 100% bunoexttm
C++ Uno Implement Environment Guard 100% bunoexttm
C++ Uno Implement Test for Environment Guard 100% bunoexttm
C++ Uno Specify Environment Descriptor 100% bunoexttm
C++ Uno Implement Environment Descriptor 100% bunoexttm
C++ Uno Implement Test for Environment Descriptor 100% bunoexttm
C++ Uno Specify Environment AntiGuard 100% bunoexttm
C++ Uno Implement Environment AntiGuard 100% bunoexttm
C++ Uno Implement Test for Environment AntiGuard 100% bunoexttm
C++ Uno Specify Purpose Bridge Implementation Helper 100% bunoexttm
C++ Uno Implement Purpose Bridge Implementation Helper 100% bunoexttm
C++ Uno Test for Purpose Bridge Implementation Helper 100% bunoexttm

Dependencies

Area Title State CWS
C++ Uno

Misc Improvements

100% krmisc (SRC680_m191)
Binary Uno

Preparation

  • enable identity mapping: getting a Uno Mapping from and to the same environment - currently the runtime does return NULL, so every client has to check for it,
  • cleanup the dll component loader
    • to use the identity mapping, and
    • to get rid of very outdated deprecated stuff
100% bunoidmap (SRC680_m196)
Binary Uno Implement Environment Tester 100% bunoexttm
Binary Uno Implement Mapping Tester 100% bunoexttm
Personal tools