Difference between revisions of "Effort/Implement Basic Threading-Architecture"

From Apache OpenOffice Wiki
Jump to: navigation, search
m (→‎Tasks: Removed clipboard and D&D, both to belong the clean up.)
m (Fixed section indention, some wording, added links.)
Line 1: Line 1:
 
Status: in progress
 
Status: in progress
  
−
==Implement Basic Threading Architecture==
+
The OOo [[Uno/Term/Threading-Architecture|threading-architecture]] is going to be well defined, many little changes need to be done to get implemented what is specified as the [[Spec/Architecture/Threading|threading-architecture]].  
−
The OOo threading is going to be well defined, many little changes need to be done to get implemented what is specified as the [[Spec/Architecture/Threading|threading architecture]].  
 
  
−
===Problem===
+
==Problem==
 
The biggest problem is the size of the code base. It is hard to actually get an overview where thread related constructs are used. Typical usages are:
 
The biggest problem is the size of the code base. It is hard to actually get an overview where thread related constructs are used. Typical usages are:
 
* use a mutex to protect an object,
 
* use a mutex to protect an object,
 
* use a thread to do something in the background,
 
* use a thread to do something in the background,
−
* use a thread to encapsularte thread affinities (e.g. in dtrans).
+
* use a thread to encapsulate thread affinities (e.g. in dtrans).
 
Some usages are more implicit:
 
Some usages are more implicit:
 
* post a user message into the VCL event queue, to delegate the execution of a particular operation into the "main" thread,
 
* post a user message into the VCL event queue, to delegate the execution of a particular operation into the "main" thread,
Line 15: Line 14:
 
* rely on VCL/Win to enter the <code>getMessage</code> loop in the main thread (DDE).
 
* rely on VCL/Win to enter the <code>getMessage</code> loop in the main thread (DDE).
  
−
===Solution===
+
==Solution==
−
Actually grep for thread related Uno code and change it, if needed. Change the environments of all possible components to "cpp:unsafe".
+
Actually grep for thread related [[Uno]] code and change it, if needed. Change the environments of all possible components to <code>"c++:unsafe"</code>.
  
−
====Threads====
+
===Threads===
 
* vos timer thread
 
* vos timer thread
 
* dtrans threads (clipboard and D&D)
 
* dtrans threads (clipboard and D&D)
Line 26: Line 25:
 
* Win32: affinity thread
 
* Win32: affinity thread
 
* office acceptor thread - second process thread
 
* office acceptor thread - second process thread
−
* uno acceptor thread
+
* Uno acceptor thread
 
* io - pump thread
 
* io - pump thread
−
* package manager deployment gui thread
+
* package manager deployment GUI thread
−
* UNO job threads
+
* Uno job threads
  
−
====Components====
+
===Components===
  
−
====Libraries====
+
===Libraries===
  
−
====Applications====
+
===Applications===
  
−
===Tasks===
+
==Tasks==
 
:{|border="1" cellspacing="0" class="wikitable"
 
:{|border="1" cellspacing="0" class="wikitable"
 
|- style="background:#efefef;"  
 
|- style="background:#efefef;"  
 
| Title || State
 
| Title || State
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://framework.openoffice.org/source/browse/framework/desktop module framework/desktop] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://framework.openoffice.org/source/browse/framework/desktop module framework/desktop] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://framework.openoffice.org/source/browse/framework/sfx2 module framework/sfx2] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://framework.openoffice.org/source/browse/framework/sfx2 module framework/sfx2] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://framework.openoffice.org/source/browse/framework/filter module framework/filter] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://framework.openoffice.org/source/browse/framework/filter module framework/filter] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://graphics.openoffice.org/source/browse/graphics/goodies module graphics/goodies] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://graphics.openoffice.org/source/browse/graphics/goodies module graphics/goodies] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://graphics.openoffice.org/source/browse/graphics/svx module graphics/svx] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://graphics.openoffice.org/source/browse/graphics/svx module graphics/svx] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://gsl.openoffice.org/source/browse/gsl/toolkit module gsl/toolkit] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://gsl.openoffice.org/source/browse/gsl/toolkit module gsl/toolkit] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://l10n.openoffice.org/source/browse/l10n/i18npool module l10n/i18npool] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://l10n.openoffice.org/source/browse/l10n/i18npool module l10n/i18npool] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://sw.openoffice.org/source/browse/sw/linguistic module sw/linguistic] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://sw.openoffice.org/source/browse/sw/linguistic module sw/linguistic] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://sw.openoffice.org/source/browse/sw/sw module sw/sw] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://sw.openoffice.org/source/browse/sw/sw module sw/sw] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://ucb.openoffice.org/source/browse/ucb/uui module ucb/uui] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://ucb.openoffice.org/source/browse/ucb/uui module ucb/uui] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://util.openoffice.org/source/browse/util/comphelper/ module util/comphelper] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://util.openoffice.org/source/browse/util/comphelper/ module util/comphelper] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://util.openoffice.org/source/browse/util/xmlhelp module util/xmlhelp] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://util.openoffice.org/source/browse/util/xmlhelp module util/xmlhelp] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://util.openoffice.org/source/browse/util/unotools module util/unotools] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://util.openoffice.org/source/browse/util/unotools module util/unotools] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://util.openoffice.org/source/browse/util/svtools module util/svtools] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://util.openoffice.org/source/browse/util/svtools module util/svtools] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://util.openoffice.org/source/browse/util/extensions module util/extensions] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://util.openoffice.org/source/browse/util/extensions module util/extensions] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://util.openoffice.org/source/browse/util/fileaccess module util/fileaccess] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://util.openoffice.org/source/browse/util/fileaccess module util/fileaccess] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://xml.openoffice.org/source/browse/xml/xmloff module xml/xmloff] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://xml.openoffice.org/source/browse/xml/xmloff module xml/xmloff] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://xml.openoffice.org/source/browse/xml/package module xml/package] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://xml.openoffice.org/source/browse/xml/package module xml/package] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://xml.openoffice.org/source/browse/xml/sax module xml/sax] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://xml.openoffice.org/source/browse/xml/sax module xml/sax] || UTF2
 
|-
 
|-
−
| Declare be [[Uno/Term/Thread Unsafe|thread unsafe]] [http://dba.openoffice.org/source/browse/dba/connectivity/ module dba/connectivity] || UTF2
+
| Declare be [[Uno/Term/Thread Unsafe|thread-unsafe]] [http://dba.openoffice.org/source/browse/dba/connectivity/ module dba/connectivity] || UTF2
 
|-
 
|-
−
| Make ZConnectionPool / OPoolTimer thread enter the default thread unsafe environment before invalidating the pooled connections. || UTF2
+
| Make ZConnectionPool / OPoolTimer thread enter the default [[Uno/Term/Thread Unsafe|thread-unsafe]] environment before invalidating the pooled connections. || UTF2
 
|-
 
|-
 
| AsyncEventNotifier / EventNotifierImpl - Already call "getComponent" at the "IEventProcessor" during construction of the "AsyncEventNotifier" and remember the object in a "free" reference || utf2
 
| AsyncEventNotifier / EventNotifierImpl - Already call "getComponent" at the "IEventProcessor" during construction of the "AsyncEventNotifier" and remember the object in a "free" reference || utf2

Revision as of 13:25, 4 September 2006

Status: in progress

The OOo threading-architecture is going to be well defined, many little changes need to be done to get implemented what is specified as the threading-architecture.

Problem

The biggest problem is the size of the code base. It is hard to actually get an overview where thread related constructs are used. Typical usages are:

  • use a mutex to protect an object,
  • use a thread to do something in the background,
  • use a thread to encapsulate thread affinities (e.g. in dtrans).

Some usages are more implicit:

  • post a user message into the VCL event queue, to delegate the execution of a particular operation into the "main" thread,
  • use the "global" mutex to do some initialization,
  • use the "Solar Mutex" to protect a particular object,
  • rely on VCL/Win to enter the getMessage loop in the main thread (DDE).

Solution

Actually grep for thread related Uno code and change it, if needed. Change the environments of all possible components to "c++:unsafe".

Threads

  • vos timer thread
  • dtrans threads (clipboard and D&D)
  • ucbhelper: background download thread
  • ICE thread
  • configuration flash thread
  • Win32: affinity thread
  • office acceptor thread - second process thread
  • Uno acceptor thread
  • io - pump thread
  • package manager deployment GUI thread
  • Uno job threads

Components

Libraries

Applications

Tasks

Title State
Declare be thread-unsafe module framework/desktop UTF2
Declare be thread-unsafe module framework/sfx2 UTF2
Declare be thread-unsafe module framework/filter UTF2
Declare be thread-unsafe module graphics/goodies UTF2
Declare be thread-unsafe module graphics/svx UTF2
Declare be thread-unsafe module gsl/toolkit UTF2
Declare be thread-unsafe module l10n/i18npool UTF2
Declare be thread-unsafe module sw/linguistic UTF2
Declare be thread-unsafe module sw/sw UTF2
Declare be thread-unsafe module ucb/uui UTF2
Declare be thread-unsafe module util/comphelper UTF2
Declare be thread-unsafe module util/xmlhelp UTF2
Declare be thread-unsafe module util/unotools UTF2
Declare be thread-unsafe module util/svtools UTF2
Declare be thread-unsafe module util/extensions UTF2
Declare be thread-unsafe module util/fileaccess UTF2
Declare be thread-unsafe module xml/xmloff UTF2
Declare be thread-unsafe module xml/package UTF2
Declare be thread-unsafe module xml/sax UTF2
Declare be thread-unsafe module dba/connectivity UTF2
Make ZConnectionPool / OPoolTimer thread enter the default thread-unsafe environment before invalidating the pooled connections. UTF2
AsyncEventNotifier / EventNotifierImpl - Already call "getComponent" at the "IEventProcessor" during construction of the "AsyncEventNotifier" and remember the object in a "free" reference utf2
Make VCL Thread Transparent in progress
Personal tools