126.96.36.199.2 Running Classification Task
The Running Classification Task is a task that runs continuously, in a loop, and monitors the Running Classification Job Queue. Because the server maintains only one Running Classification Job Queue, there is only one Running Classification Task in the server.
Whenever the Running Classification Job Queue is not empty, the task searches for one Running Job in the queue for which the parent Classification Job – identified by the Running Job.Parent reference – has a Running status of FsrmReportRunningStatus_Queued. The task processes such an object by performing the following actions in sequence:
Set the parent instance's Running status to FsrmReportRunningStatus_Running.
Create an empty volatile list of file references that will be referred to as Report item list for the remaining steps.
The server performs the following steps listed here, in sequence, for each file whose path resides in at least one of the parent instance's Classification Job.Namespace Roots.
If the Running Job's Running Job.Cancel property is true, skip to the Report step below.
Perform the Retrieve stored classification properties for the file.
Perform the Generate new classification properties action for the file given the list of Property Definition Instances from the preceding action. If the property definition instance.flags of any of the resulting Property Definition Instances contains FsrmPropertyFlags_SetByClassifier, add the file to the Report item list.
Perform the Store classification properties action for the file given the list of Property Definition Instances from the preceding action.
Report Step (in sequence):
If the parent instance's Generate classification report is false, skip the Report step.
For each report format in the parent instance's Classification Job.Formats, generate a classification report of that format for the items in the Report item list.
Store all generated reports as files in Reports directory. All file names MUST begin with Report.Last generated file name prefix.
After the Report Step (in sequence):
Set the parent instance's Classification Job.Last error to an empty string – if no errors occurred – or to a string describing the error encountered.
Set the parent instance's Last generated path to Reports directory.
If reports were generated, send emails with the generated reports to the email address recipient list in the parent instance's Classification Job.Mail to, as follows:
If the parent instance's Classification Job.Mail to is an empty string, the server MUST NOT email the report when the action is run.
If the parent instance's Classification Job.Mail to contains the string "[ADMIN EMAIL]", the server MUST send the report to the Administrator email address returned from IFsrmSetting::AdminEmail (get), in addition to other email addresses in Mail to, when emailing the report.
Set the parent instance's Running status to FsrmReportRunningStatus_NotRunning.
Remove the Running Report Job from the Running Classification Job Queue.