myObjectiveOLAP Server, Process Manager Technical Implementation


An Oracle Database administrator may want to understand the technical implementation of the myObjectiveOLAP Process Manager.   This note together with the Process Manager Flow Diagram found here, are designed to aide that understanding.


myObjectiveOLAP Server's Process Manager is based on the standard Oracle database RDBMS scheduler.


You must ensure that you connect to the Oracle Database as the MOOSERVER user before starting or stopping the Process Manager from sqlPlus.  

Running the Process Manager as a different user is not supported.


Start the Process Manager from sqlPlus


When the Process Manager is started a statement similar to the following PLSQL statement is executed, passing the polling interval as set from the Process Manager graphical interface.


BEGIN DBMS_SCHEDULER.create_job ( job_name => 'MOOPROCESSOR', job_type => 'PLSQL_BLOCK', job_action => 'BEGIN dbms_aw.execute(''aw attach MOOSERVER.PRD; PRD; aw detach MOOSERVER.PRD''); END;', start_date => SYSTIMESTAMP, repeat_interval => 'freq= SECONDLY; INTERVAL=[INTERGER_POLL_TIME_SECONDS],end_date => NULL, enabled => TRUE, comments => 'myObjectiveOLAP Server Process Manager'); END;


The myObjectiveOLAP Process Manager graphical user interface also allows a "Run One Process" option, this executes the following which causes PRD (Process Manager daemon) to execute only one job before turning the Process Manager off.


BEGIN DBMS_SCHEDULER.create_job ( job_name => 'MOOPROCESSOR', job_type => 'PLSQL_BLOCK', job_action => 'BEGIN dbms_aw.execute(''aw attach MOOSERVER.PRD; PRD; aw detach MOOSERVER.PRD''); END;', start_date => SYSTIMESTAMP, repeat_interval => null ,end_date => NULL, enabled => TRUE, comments => 'myObjectiveOLAP Server Process Manager'); END;


By understanding how the Process Manager is started it would be possible to script the starting of the process manager daemon.


Stop the Process Manager from sqlPlus


When the Process Manager is asked to stop the following PLSQL is executed.    


BEGIN DBMS_SCHEDULER.stop_job ('MOOPROCESSOR'); END;

BEGIN DBMS_SCHEDULER.disable('MOOPROCESSOR'); END;

BEGIN DBMS_SCHEDULER.drop_job ('MOOPROCESSOR'); END;


This may be useful in ensuring no jobs are running when you wish to bring down the Oracle Database or backup your mooData analytic workspace.


Note* When asked to stop the myObjectiveOLAP Process Manager stops almost immediately, if it is currently processing a task the Process is terminated and a ROLLBACK executed.


Checking the Current Status of the Process Manager from sqlPlus


The following sql select statement displays information from DBA_SCHEDULER_JOBS on the current status of the myOnjectiveOLAP Process Manager.


Select * from dba_scheduler_jobs WHERE JOB_NAME = 'MOOPROCESSOR';


Start the Process Manager from a myObjectiveOLAP Console Session


A myObjectiveOLAP Server application administrator may wish to run the Process Manager daemon directly from Oracle OLAP.  To do this you should start an OLAP Console session as the MOOSERVER RDBMS user and detach all Analytic Workspaces either through the AW DETACH OLAP DML statement or the Analytic Workspace selector.   They should then attach the PRD Analytic Workspace either through the "AW ATTACH PRD ro" command followed by executing PRD: "call PRD".  The Process Manager will process the next task and then exit.