flowable / flowable/flowable-engine

batchMigrateCaseInstancesOfCaseDefinition has not been implemented using case definition id

Open
#2,835 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
9.5k
Forks
2.9k
Avg merge
7h 8m
Merged PRs (30d)
2

Description

**Describe the bug**
Please check the class CaseInstanceMigrationManagerImpl seems like the following method has not been implemented:
batchMigrateCaseInstancesOfCaseDefinition(String caseDefinitionId, CaseInstanceMigrationDocument document, CommandContext commandContext)

**Expected behavior**
Should behave similarly to batchMigrateCaseInstancesOfCaseDefinition(String caseDefinitionKey, int caseDefinitionVersion, String caseDefinitionTenantId, CaseInstanceMigrationDocument document, CommandContext commandContext)

If we compare the mentioned methods only difference is, how are we getting the caseDefinitionId, but once we have the same the behavior should be same.

**Code**

@Override
public Batch batchMigrateCaseInstancesOfCaseDefinition(String caseDefinitionKey, int caseDefinitionVersion, String caseDefinitionTenantId, CaseInstanceMigrationDocument document, CommandContext commandContext) {
CaseDefinition caseDefinition = resolveCaseDefinition(caseDefinitionKey, caseDefinitionVersion, caseDefinitionTenantId, commandContext);
return batchMigrateCaseInstancesOfCaseDefinition(caseDefinition.getId(), document, commandContext);
}

@Override
public Batch batchMigrateCaseInstancesOfCaseDefinition(String caseDefinitionId, CaseInstanceMigrationDocument document, CommandContext commandContext) {
throw new UnsupportedOperationException("not implemented"); // TODO
}

**Additional context**
It is difficult to use batchMigrateCaseInstancesOfCaseDefinition(String caseDefinitionKey, int caseDefinitionVersion, String caseDefinitionTenantId, CaseInstanceMigrationDocument document, CommandContext commandContext), when no tenet setup. As in db, there will be null value and following the same if we pass null in the methods, then will get exception while creating the command context, so it's not possible. Please check following classes as caseDefinitionId always set to to null considering the methods have not been implemented CaseInstanceMigrationValidationCmd and CaseInstanceMigrationBatchCmd.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.