flowable / flowable/flowable-engine

batchMigrateCaseInstancesOfCaseDefinition has not been implemented using case definition id

Aperta
#2,835 1 commento 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
Java
Stelle
9.5k
Fork
2.9k
Merge medio
7h 8m
PR unite (30g)
2

Descrizione

**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.

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Direzione di ricerca

Inizia da CaseInstanceMigrationManagerImpl e confronta l’overload per case-definition-key con l’overload per case-definition-id. Poi esamina CaseInstanceMigrationValidationCmd e CaseInstanceMigrationBatchCmd, dove l’issue segnala che caseDefinitionId è sempre null. Il lavoro è completato quando il metodo basato sull’id si comporta come il metodo key/version/tenant e i comandi correlati mantengono l’id della definizione del caso.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
java
Ambito
backend
Tipo di issue
Bug
Difficoltà
3/5
Tempo stimato
1-2 giorni
Stato di attività
Ferma
Chiarezza
Specificata chiaramente
Idoneità per principianti
30/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.