Emakin performs most of its heavy operations in on the background to achieve scalable scalable and high performance outputoutputs. These background operations are executed by emakin Emakin’s service agent without any user interaction.
When a new process started is initiated by a user, workflow state is recorded in the database without any further processing, and creates a couple of background jobs. Service agents pulls retrieve the jobs from the queue and try to process in on the background. If an error occurs while processing a job, transaction state is rollbacked and error state is reported to the system administrators. When an administrator resolves the an issue, job is re-queued in the system, from the job manager, to the process again. Some of the errors are automatically recovered by the system and queued again with time delay.
...
Service agents uses use multiple threads, and can also can be deployed to any number of hardware instances to perform parallel execution. Jobs are executed in order of priority, and a single service agent can complete 600 job jobs per minute for the basic workflow operations. This number is highly depends dependent on the job definition and hardware specifications.
Job Details
Each job has the following properties;:
Type
Type of a job.
Created At
Date and time of when a job is created.
Delete After
Date and time of job to deleteafter which the job will be deleted.
Started At
Start date and time of a job.
Completed At
Completion date and time of a job.
Duration
Duration of execution if a job is completed, or duration of wait time in a queue.
Score
Calculated priority score. This value is calculated from a job type priority and a workflow instance priority.
State
State of a job. Can be one of the following values; Waiting, Processing, Error, Completed, Aborted.
State Transition
Every job is created in the "Waiting" state.
When a service agent pulls the job from the queue, agent is locks the job and changes state to the "Processing" state.
If the job is completed successfully successfully completed, the state changes to "Completed".
If the job is generates an error, state changes to "Error", and system administrator is notified. Some of the job errors are automatically handled. For example, e-mail sending job errors are ignored and re-scheduled, and state changes to "Waiting" to try again later. If maximum try count limit is exceeded, the state is changed to the "Error" or "Aborted" by the configuration settings.
For "Aborted" and "Completed" states, job is automatically deleted from the system if the "Delete After" date is passed.
...
Job Log
Each job contains a log about detailed information whats of what is performed in the background. Each log line has a an in log level like Debug, Information, Warning, Error.
...
Job Types
Workflow Jobs
...
Time based generic job. This job usually create creates another jobs if any action required.
Task Evaluation
Created when the initiate type workflow task is scheduled to start periodically. Created by the Scheduled Task for per task definition. You can find more detail details in the Task Evaluation section.
Work Item Evaluation
Created when the normal type workflow task is scheduled to check periodically. Created by the Scheduled Task for per work item instance. You can find more detail in details in the Task Evaluation section.
Work Item Processing
Created when a user or a system complete completes a work item. This job advances to the next step in the workflow, and executes the scripts in the workflow, calculates the role scripts to assign to which should be assigned to the task.
Deadlined Work Item
Created when a work item is 's deadline occurs. This job is similar to the "Work Item Processing" job, but created when the deadline date is missed.
Work Item Reminder
Created when a task reminder need needs to be sent.
Xml Database Jobs
Form Data Xml Database Replication
Created when the workflow data need needs to be replicate replicated on an xml database. This job is usually created when a workflow data is modified.
...
Created when a workflow history is changed and need needs to be replicate replicated on an xml database.
Xml Database Removal
Created when a worfklow workflow data is removed. This job is usually created on when a process version is deleted from the system.
Full Text Indexing Jobs
...
Created when a previously added document is removed from the full text catalog.
Domain Jobs
E-Mail Message Send
Created when a an email message is sent. Email content may be automatically generated from the workflow templates or scripting environment.
...
Created periodically to upgrade installed processes from the market store.
Domain Deletion
...
Emakin uses following default configuration to manage the job queue.
Name | Internal Name | Priority | Delete After (days) | Retry Duration (min) | Max Retry | Max Retry Result | Error Result | Alert Error | Alert Abort |
---|
Timeout (min) | Alert To |
---|---|
Document Full Text Indexing | Workflow. |
Document.FullText |
Low |
2 |
60 |
20 |
10 |
System Admin | |
Domain Deletion | Workflow. |
Domain. |
Delete |
Low |
None |
System Admin | |||||||||||
Domain Upgrade | Workflow.Domain.Upgrade | Low | 180 | True | 10 | System Admin | |||||
Form Data Xml Database Replication | Workflow.FormData.XmlDatabase | Normal | 2 | 60 | 10 | 10 | System Admin | ||||
Xml Database Removal | Workflow.FormData.XmlDatabaseRemover | Normal | 2 | 60 | 10 | 10 | System Admin | ||||
Full Text Removal | Workflow.FullText.Remover | Low | 2 | 60 | 10 | 10 | System Admin | ||||
Instance Xml Database Replication | Workflow. |
Instance.XmlDatabase | Normal | 2 |
60 | 10 |
10 |
System Admin | |
E-Mail Message Send | Workflow. |
Message.Send | Low | 90 | 5 | 10 | False | False | 10 | ||||
Scheduled Task | Workflow.ScheduledTask | High | 10 | 10 | |||||||
Deadlined Work Item | Workflow.WorkItem.Deadline | High | 180 | 10 | 20 | True | 60 | ||||
Instance Full Text Indexing | Workflow. |
Instance.FullText | Low | 2 |
...
10 | 10 | 10 | System Admin | ||||||||
Work Item Processing | Workflow.WorkItem.Process | High | 180 | 10 | 20 | Error | True | 60 | |||
Work Item Reminder | Workflow.WorkItem.Reminder | High | 60 | 10 | System Admin | ||||||
Work Item Evaluation | Workflow.WorkItem.Evaluate | High | 180 | 10 | 20 | 60 | |||||
Task Evaluation | Workflow.Task.Evaluate | High | 180 | 60 | |||||||
File Replication | Workflow.File.Replication | Normal | 30 | 1440 | 10 | 10 | System Admin | ||||
Instance Terminate | Workflow.Instance.Terminate | Low | 180 | 60 | |||||||
Channel Synchronization | Workflow.Channel.MailSync | Normal | 20 | 10 | 3 | 60 | |||||
Case Full Text Indexing | Workflow.Case.FullText | Low | 20 | 10 | System Admin | ||||||
Case Deadline Notification | Workflow.Case.Deadline | High | 180 | 60 | System Admin | ||||||
Case Reminder | Workflow.Case.Reminder | Normal | 60 | 60 | System Admin | ||||||
Case Violation Notification | Workflow.Case.Violation | Normal | 60 | 10 | System Admin |