Package de.xima.fc.timing
Class JobKeyFactory
- java.lang.Object
-
- de.xima.fc.timing.JobKeyFactory
-
public class JobKeyFactory extends Object
Factory for creating a job key for formcycle specific jobs.- Author:
- XIMA MEDIA GmbH
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
JobKeyFactory.JobGroups
Enumeration of the predefined job groups
-
Constructor Summary
Constructors Constructor Description JobKeyFactory()
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static long
extractWorkflowTriggerId(String jobName)
static long
extractWorkflowTriggerId(org.quartz.JobDetail job)
static long
extractWorkflowTriggerId(org.quartz.JobKey jobKey)
static String
extractWorkflowTriggerProcessDbId(String jobGroup)
static String
extractWorkflowTriggerProcessDbId(org.quartz.JobDetail job)
static String
extractWorkflowTriggerProcessDbId(org.quartz.JobKey jobKey)
static String
extractWorkflowTriggerProcessId(String jobGroup)
Deprecated.static String
extractWorkflowTriggerProcessId(org.quartz.JobDetail job)
Deprecated.static String
extractWorkflowTriggerProcessId(org.quartz.JobKey jobKey)
Deprecated.static String
extractWorkflowTriggerType(String jobGroup)
static String
extractWorkflowTriggerType(org.quartz.JobDetail job)
static String
extractWorkflowTriggerType(org.quartz.JobKey jobKey)
static org.quartz.JobKey
getClientCounterKey(ClientCounter counter)
static org.quartz.JobKey
getPluginUpdateCheckKey()
static org.quartz.JobKey
getProtocolCleanupKey()
static org.quartz.JobKey
getRefreshTokenCleanupKey()
static org.quartz.JobKey
getStatusChangeKey(Vorgang process)
static org.quartz.JobKey
getSystemCleanupKey()
static String
getWorkflowTriggerGroup(WorkflowTrigger trigger, Vorgang formRecord)
The group of the quartz job for a timed workflow trigger.static String
getWorkflowTriggerGroup(WorkflowTrigger trigger, String processId)
Deprecated.static String
getWorkflowTriggerGroup(String triggerType, Vorgang formRecord)
Deprecated.static String
getWorkflowTriggerGroup(String triggerType, String processId)
Deprecated.static String
getWorkflowTriggerGroupByDbId(WorkflowTrigger trigger, long formRecordId, long projectId, long clientId)
The group of the quartz job for a timed workflow trigger.static String
getWorkflowTriggerGroupByDbId(WorkflowTrigger trigger, Vorgang formRecord)
The group of the quartz job for a timed workflow trigger.static String
getWorkflowTriggerGroupByDbId(String triggerType, long formRecordId, long projectId, long clientId)
The group of the quartz job for a timed workflow trigger.static String
getWorkflowTriggerGroupByDbId(String triggerType, Vorgang formRecord)
The group of the quartz job for a timed workflow trigger.static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey>
getWorkflowTriggerGroupMatcherByClientId(long clientId)
static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey>
getWorkflowTriggerGroupMatcherByProjectId(long projectId)
static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey>
getWorkflowTriggerGroupMatcherForFormRecord(Vorgang formRecord)
Deprecated.static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey>
getWorkflowTriggerGroupMatcherForFormRecord(String processId)
Deprecated.static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey>
getWorkflowTriggerGroupMatcherForFormRecordByDbId(long formRecordId)
static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey>
getWorkflowTriggerGroupMatcherForFormRecordByDbId(Vorgang formRecord)
static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey>
getWorkflowTriggerGroupMatcherForTrigger(WorkflowTrigger trigger)
static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey>
getWorkflowTriggerGroupMatcherForTrigger(String triggerType)
static org.quartz.JobKey
getWorkflowTriggerKey(WorkflowTrigger trigger, Vorgang formRecord)
Deprecated.static org.quartz.JobKey
getWorkflowTriggerKeyByDbId(WorkflowTrigger trigger, Vorgang formRecord)
static String
getWorkflowTriggerName(WorkflowTrigger trigger)
-
-
-
Method Detail
-
extractWorkflowTriggerId
public static long extractWorkflowTriggerId(org.quartz.JobDetail job)
- Parameters:
job
- Job to process.- Returns:
- The trigger ID in the job key, as created by
getWorkflowTriggerKey(WorkflowTrigger, Vorgang)
-
extractWorkflowTriggerId
public static long extractWorkflowTriggerId(org.quartz.JobKey jobKey)
- Parameters:
jobKey
- Job key to process.- Returns:
- The trigger ID in the trigger key, as created by
getWorkflowTriggerKey(WorkflowTrigger, Vorgang)
-
extractWorkflowTriggerId
public static long extractWorkflowTriggerId(String jobName)
- Parameters:
jobName
- Job group to process.- Returns:
- The process ID in the job name, as created by
getWorkflowTriggerName(WorkflowTrigger)
.
-
extractWorkflowTriggerProcessDbId
public static String extractWorkflowTriggerProcessDbId(org.quartz.JobDetail job)
- Parameters:
job
- Job to process.- Returns:
- The process database ID in the job key, as created by
getWorkflowTriggerKey(WorkflowTrigger, Vorgang)
-
extractWorkflowTriggerProcessDbId
public static String extractWorkflowTriggerProcessDbId(org.quartz.JobKey jobKey)
- Parameters:
jobKey
- Job key to process.- Returns:
- The process database ID in the job key, as created by
getWorkflowTriggerKey(WorkflowTrigger, Vorgang)
-
extractWorkflowTriggerProcessDbId
public static String extractWorkflowTriggerProcessDbId(String jobGroup)
- Parameters:
jobGroup
- Job group to process.- Returns:
- The process database ID in the job key, as created by
getWorkflowTriggerGroup(String, String)
-
extractWorkflowTriggerProcessId
@Deprecated public static String extractWorkflowTriggerProcessId(org.quartz.JobDetail job)
Deprecated.- Parameters:
job
- Job to process.- Returns:
- The process ID in the job key, as created by
getWorkflowTriggerKey(WorkflowTrigger, Vorgang)
-
extractWorkflowTriggerProcessId
@Deprecated public static String extractWorkflowTriggerProcessId(org.quartz.JobKey jobKey)
Deprecated.- Parameters:
jobKey
- Job key to process.- Returns:
- The process ID in the job key, as created by
getWorkflowTriggerKey(WorkflowTrigger, Vorgang)
-
extractWorkflowTriggerProcessId
@Deprecated public static String extractWorkflowTriggerProcessId(String jobGroup)
Deprecated.- Parameters:
jobGroup
- Job group to process.- Returns:
- The process ID in the job key, as created by
getWorkflowTriggerGroup(String, String)
-
extractWorkflowTriggerType
public static String extractWorkflowTriggerType(org.quartz.JobDetail job)
- Parameters:
job
- Job to process.- Returns:
- The trigger type in the job key, as created by
getWorkflowTriggerKey(WorkflowTrigger, Vorgang)
.
-
extractWorkflowTriggerType
public static String extractWorkflowTriggerType(org.quartz.JobKey jobKey)
- Parameters:
jobKey
- Job key to process.- Returns:
- The trigger type in the job key, as created by
getWorkflowTriggerKey(WorkflowTrigger, Vorgang)
.
-
extractWorkflowTriggerType
public static String extractWorkflowTriggerType(String jobGroup)
- Parameters:
jobGroup
- Job group to process.- Returns:
- The trigger type in the job key, as created by
getWorkflowTriggerGroup(String, String)
-
getClientCounterKey
public static org.quartz.JobKey getClientCounterKey(ClientCounter counter)
-
getPluginUpdateCheckKey
public static org.quartz.JobKey getPluginUpdateCheckKey()
- Returns:
JobKey
for the plugin update check job
-
getProtocolCleanupKey
public static org.quartz.JobKey getProtocolCleanupKey()
- Returns:
JobKey
for the protocol clean up job
-
getStatusChangeKey
public static org.quartz.JobKey getStatusChangeKey(Vorgang process)
- Parameters:
process
-Vorgang
the process to create an job key- Returns:
JobKey
for the given process
-
getSystemCleanupKey
public static org.quartz.JobKey getSystemCleanupKey()
- Returns:
- The job key for the system cleanup job.
-
getRefreshTokenCleanupKey
public static org.quartz.JobKey getRefreshTokenCleanupKey()
- Returns:
- The job key for the system cleanup job.
-
getWorkflowTriggerGroup
@Deprecated public static String getWorkflowTriggerGroup(String triggerType, String processId)
Deprecated.The group of the quartz job for a timed workflow trigger. It is of the following form:_WORKFLOW_TRIGGER_ WORKFLOW_TRIGGER
is used as a separator so we can search for triggers both by type and by form record UUID.Example:
WORKFLOW_TRIGGER_FC_STATE_TIMER_WORKFLOW_TRIGGER_9866b1fd-d288-4595-a37e-7e39efa059e3
- Parameters:
triggerType
- The type of the trigger for which to create the group.processId
- Process ID of the form record for which to create the group.- Returns:
- The quartz job group for the given form record and trigger type.
-
getWorkflowTriggerGroup
@Deprecated public static String getWorkflowTriggerGroup(String triggerType, Vorgang formRecord)
Deprecated.The group of the quartz job for a timed workflow trigger. SeegetWorkflowTriggerGroup(String, String)
for more details.- Parameters:
triggerType
- The type of the trigger for which to create the group.formRecord
- Form record for which to create the group.- Returns:
- The quartz job group for the given form record and trigger type.
-
getWorkflowTriggerGroup
@Deprecated public static String getWorkflowTriggerGroup(WorkflowTrigger trigger, String processId)
Deprecated.The group of the quartz job for a timed workflow trigger. SeegetWorkflowTriggerGroup(String, String)
for more details.- Parameters:
trigger
- The trigger for which to create the group.processId
- The process ID of the form record for which to create the group.- Returns:
- The quartz job group for the given form record and trigger type.
-
getWorkflowTriggerGroup
public static String getWorkflowTriggerGroup(WorkflowTrigger trigger, Vorgang formRecord)
The group of the quartz job for a timed workflow trigger. SeegetWorkflowTriggerGroup(String, String)
for more details.- Parameters:
trigger
- The trigger for which to create the group.formRecord
- Form record for which to create the group.- Returns:
- The quartz job group for the given form record and trigger type.
-
getWorkflowTriggerGroupByDbId
public static String getWorkflowTriggerGroupByDbId(String triggerType, long formRecordId, long projectId, long clientId)
The group of the quartz job for a timed workflow trigger. It is of the following form:_WORKFLOW_TRIGGER_ _pid# _cid# WORKFLOW_TRIGGER
is used as a separator so we can search for triggers by type, by form record ID, by project ID and by clientId.Example:
FC_STATE_TIMER_WORKFLOW_TRIGGER_444_pid#333_cid#222
- Parameters:
triggerType
- The type of the trigger for which to create the group.formRecordId
- Process ID of the form record for which to create the group.projectId
- Project ID of the project from the form record for which to create the group.clientId
- Client ID of the client from the form record for which to create the group.- Returns:
- The quartz job group for the given form record ID, project ID, client ID and trigger type.
-
getWorkflowTriggerGroupByDbId
public static String getWorkflowTriggerGroupByDbId(String triggerType, Vorgang formRecord)
The group of the quartz job for a timed workflow trigger. SeegetWorkflowTriggerGroupByDbId(String, long, long, long)
for more details.- Parameters:
triggerType
- The type of the trigger for which to create the group.formRecord
- Form record for which to create the group.- Returns:
- The quartz job group for the given form record and trigger type.
-
getWorkflowTriggerGroupByDbId
public static String getWorkflowTriggerGroupByDbId(WorkflowTrigger trigger, long formRecordId, long projectId, long clientId)
The group of the quartz job for a timed workflow trigger. SeegetWorkflowTriggerGroupByDbId(String, long, long, long)
for more details.- Parameters:
trigger
- The trigger for which to create the group.formRecordId
- The process ID of the form record for which to create the group.projectId
- Project ID of the project from the form record for which to create the group.clientId
- Client ID of the client from the form record for which to create the group.- Returns:
- The quartz job group for the given form record ID, project ID, client ID and trigger type.
-
getWorkflowTriggerGroupByDbId
public static String getWorkflowTriggerGroupByDbId(WorkflowTrigger trigger, Vorgang formRecord)
The group of the quartz job for a timed workflow trigger. SeegetWorkflowTriggerGroupByDbId(String, long, long, long)
for more details.- Parameters:
trigger
- The trigger for which to create the group.formRecord
- Form record for which to create the group.- Returns:
- The quartz job group for the given form record and trigger type.
-
getWorkflowTriggerGroupMatcherForFormRecord
@Deprecated public static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey> getWorkflowTriggerGroupMatcherForFormRecord(String processId)
Deprecated.- Parameters:
processId
- Process ID of a form record for which to find jobs.- Returns:
- A group matcher for all
Job
s that were created for the given form record, irrespective of their trigger type.
-
getWorkflowTriggerGroupMatcherForFormRecord
@Deprecated public static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey> getWorkflowTriggerGroupMatcherForFormRecord(Vorgang formRecord)
Deprecated.- Parameters:
formRecord
- A form record for which to find jobs.- Returns:
- A group matcher for all
Job
s that were created for the given form record, irrespective of their trigger type.
-
getWorkflowTriggerGroupMatcherForFormRecordByDbId
public static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey> getWorkflowTriggerGroupMatcherForFormRecordByDbId(long formRecordId)
- Parameters:
formRecordId
- Form record ID of a form record for which to find jobs.- Returns:
- A group matcher for all
Job
s that were created for the given form record, irrespective of their trigger type.
-
getWorkflowTriggerGroupMatcherForFormRecordByDbId
public static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey> getWorkflowTriggerGroupMatcherForFormRecordByDbId(Vorgang formRecord)
- Parameters:
formRecord
- A form record for which to find jobs.- Returns:
- A group matcher for all
Job
s that were created for the given form record, irrespective of their trigger type.
-
getWorkflowTriggerGroupMatcherByProjectId
public static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey> getWorkflowTriggerGroupMatcherByProjectId(long projectId)
- Parameters:
projectId
- The project ID to find quartz triggers.- Returns:
- A group matcher for all
Job
s of workflow triggers that are scheduled for the given project ID, irrespective of their type.
-
getWorkflowTriggerGroupMatcherByClientId
public static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey> getWorkflowTriggerGroupMatcherByClientId(long clientId)
- Parameters:
clientId
- The client ID to find quartz triggers.- Returns:
- A group matcher for all
Job
s of workflow triggers that are scheduled for the given client ID, irrespective of their type.
-
getWorkflowTriggerGroupMatcherForTrigger
public static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey> getWorkflowTriggerGroupMatcherForTrigger(String triggerType)
- Parameters:
triggerType
- Type of a workflow trigger for which to find jobs.- Returns:
- A group matcher for all
Job
s that belong to thegetWorkflowTriggerGroup(String, Vorgang)
for a given trigger type, irrespective of theVorgang
.
-
getWorkflowTriggerGroupMatcherForTrigger
public static org.quartz.impl.matchers.GroupMatcher<org.quartz.JobKey> getWorkflowTriggerGroupMatcherForTrigger(WorkflowTrigger trigger)
- Parameters:
trigger
- A workflow trigger for which to find jobs.- Returns:
- A group matcher for all
Job
s that belong to thegetWorkflowTriggerGroup(String, Vorgang)
for a given trigger type, irrespective of theVorgang
.
-
getWorkflowTriggerKey
@Deprecated public static org.quartz.JobKey getWorkflowTriggerKey(WorkflowTrigger trigger, Vorgang formRecord)
Deprecated.- Parameters:
trigger
- The workflow trigger for which to create a key.formRecord
- The form record for which to create a key.- Returns:
- A
TriggerKey
for the trigger within the given form record.
-
getWorkflowTriggerKeyByDbId
public static org.quartz.JobKey getWorkflowTriggerKeyByDbId(WorkflowTrigger trigger, Vorgang formRecord)
- Parameters:
trigger
- The workflow trigger for which to create a key.formRecord
- The form record for which to create a key.- Returns:
- A
TriggerKey
for the trigger within the given form record.
-
getWorkflowTriggerName
public static String getWorkflowTriggerName(WorkflowTrigger trigger)
- Parameters:
trigger
- Trigger for which to retrieve the name.- Returns:
- The job name for the given workflow trigger.
-
-