You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@felix.apache.org by pd...@apache.org on 2015/03/09 22:14:03 UTC
svn commit: r1665358 - in
/felix/site/trunk/content/documentation/subprojects/apache-felix-dependency-manager-4/reference:
diagrams/concurrent-serial-queue.png diagrams/serial-queue.png
thread-model.mdtext
Author: pderop
Date: Mon Mar 9 21:14:03 2015
New Revision: 1665358
URL: http://svn.apache.org/r1665358
Log:
Trying to add some diagrams to illustrate the new thread model.
Added:
felix/site/trunk/content/documentation/subprojects/apache-felix-dependency-manager-4/reference/diagrams/concurrent-serial-queue.png (with props)
felix/site/trunk/content/documentation/subprojects/apache-felix-dependency-manager-4/reference/diagrams/serial-queue.png (with props)
Modified:
felix/site/trunk/content/documentation/subprojects/apache-felix-dependency-manager-4/reference/thread-model.mdtext
Added: felix/site/trunk/content/documentation/subprojects/apache-felix-dependency-manager-4/reference/diagrams/concurrent-serial-queue.png
URL: http://svn.apache.org/viewvc/felix/site/trunk/content/documentation/subprojects/apache-felix-dependency-manager-4/reference/diagrams/concurrent-serial-queue.png?rev=1665358&view=auto
==============================================================================
Binary file - no diff available.
Propchange: felix/site/trunk/content/documentation/subprojects/apache-felix-dependency-manager-4/reference/diagrams/concurrent-serial-queue.png
------------------------------------------------------------------------------
svn:mime-type = image/png
Added: felix/site/trunk/content/documentation/subprojects/apache-felix-dependency-manager-4/reference/diagrams/serial-queue.png
URL: http://svn.apache.org/viewvc/felix/site/trunk/content/documentation/subprojects/apache-felix-dependency-manager-4/reference/diagrams/serial-queue.png?rev=1665358&view=auto
==============================================================================
Binary file - no diff available.
Propchange: felix/site/trunk/content/documentation/subprojects/apache-felix-dependency-manager-4/reference/diagrams/serial-queue.png
------------------------------------------------------------------------------
svn:mime-type = image/png
Modified: felix/site/trunk/content/documentation/subprojects/apache-felix-dependency-manager-4/reference/thread-model.mdtext
URL: http://svn.apache.org/viewvc/felix/site/trunk/content/documentation/subprojects/apache-felix-dependency-manager-4/reference/thread-model.mdtext?rev=1665358&r1=1665357&r2=1665358&view=diff
==============================================================================
--- felix/site/trunk/content/documentation/subprojects/apache-felix-dependency-manager-4/reference/thread-model.mdtext (original)
+++ felix/site/trunk/content/documentation/subprojects/apache-felix-dependency-manager-4/reference/thread-model.mdtext Mon Mar 9 21:14:03 2015
@@ -17,7 +17,11 @@ the "master" and will immediately execut
then a job (J2) for this new event is just enqueued in the Serial Queue, but the other thread returns immediately to the caller, and the job J2 will then be executed by the "master" thread
(after J1).
-This mechanism allows to serially handle all Component events (service dependencies) in FIFO order without maintaining any locks.
+This mechanism allows to serially handle all Component events (service dependencies) in FIFO order without maintaining any locks.
+
+The following diagram illustrates the thread model we just described:
+
+<img src="./diagrams/serial-queue.png" width="25%">
# Enabling parallelism with a ComponentExecutorFactory
@@ -29,6 +33,10 @@ typically a shared threadpool configured
jobs scheduled in the Serial Queue of a given Component are still executed one at a time, in FIFO order and the Component remains single threaded, and independent Components may then each
be managed and activated concurrently with respect to each other.
+Here is a diagram which illustrates all this:
+
+<img src="./diagrams/concurrent-serial-queue.png" width="25%">
+
If you want to ensure that all Components are initialized after the ComponentExecutorFactory is registered in the OSGI registry, you can use the "org.apache.felix.dependencymanager.parallel"
OSGi system property which specifies the list of components which must wait for the ComponentExecutorFactory service. This property value can be set to a wildcard ("*"), or a list of
components implementation class prefixes (comma separated). So, all components whose class name starts with the specified prefixes will be cached until the ComponentExecutorFactory service