Expand description of the LUCStarter
authorFrancisco Redondo Marchena <francisco.marchena@codethink.co.uk>
Thu, 9 Aug 2012 10:31:02 +0000 (11:31 +0100)
committerJonathan Maw <jonathan.maw@codethink.co.uk>
Fri, 10 Aug 2012 09:10:32 +0000 (10:10 +0100)
Includes a step-by-step description of how to start the Last User
Context.

node-startup-controller/luc-starter.c

index 6e67f10..8032dc7 100644 (file)
 
 
 
+/**
+ * SECTION: luc-starter
+ * @title: LUCStarter
+ * @short_description: Starts the applications registered with the Last User Context.
+ * @stability: Internal
+ *
+ * The #LUCStarter is a component of the #NodeStartupControllerApplication which manages 
+ * the start of the Last User Context (LUC) applications.
+ * 
+ * When the #NodeStartupControllerApplication starts, it asks the #LUCStarter to start
+ * the LUC applications. To start the LUC applications, the #LUCStarter will do the
+ * following in order:
+ *
+ * 1. Checks with the Node State Manager (NSM) if starting the LUC applications
+ *    is required. If it is not required, it notifies the groups of current applications
+ *    that the start of the LUC has been processed, which never happens because starting
+ *    the LUC is not required.
+ *
+ * If starting the LUC is required:
+ *
+ * 2. Removes the current user context.
+ *
+ * 3. Reads the LUC using the node_startup_controller_service_read_luc().
+ *
+ * 4. Starts the LUC applications asynchronously and in prioritised groups. The group of
+ *    applications, which belong to the most prioritised LUC type, start first and then
+ *    the next group of applications are started in the order of the prioritized types
+ *    set at build-time, then in numerical order.
+ *    When an application is started, the #LUCStarter keeps it in a table, associates
+ *    this application with its #GCancellable (so it is possible to cancel each
+ *    respective application if the start of the LUC is cancelled), and start the service
+ *    calling the start method to #JobManager and passing its #GCancellable.
+ *
+ * 5. Notifies the groups of applications that the start of the LUC has been processed.
+ *    
+ */
+
+
+
 DLT_IMPORT_CONTEXT (controller_context);
 
 
@@ -81,21 +120,6 @@ static void luc_starter_start_groups_for_real     (LUCStarter   *starter);
 
 
 
-/**
- * SECTION: luc-starter
- * @title: LUCStarter
- * @short_description: Starts the applications registered with the Last User Context
- * @stability: Internal
- *
- * The #LUCStarter starts the Last User Context (LUC) applications. The LUC applications
- * are started asynchronously and in groups (one group per LUC type).
- * The #LUCStarter checks with Node State Manager (NSM) if starting the LUC applications
- * is required. If it is required, the #LUCStarter will start the LUC applications.
- * Notice that it is possible to cancel the start of the LUC applications.
- */
-
-
-
 struct _LUCStarterClass
 {
   GObjectClass __parent__;