flowable/flowable-engine · error · FlowableObjectNotFoundException
Could not find a batch part with id
Error message
Could not find a batch part with id '${batchPartId}'. What it means
Lookup failure in BatchPartBaseResource.validateBatchPart: ManagementService.getBatchPart returned null for the given batchPartId, so no such batch part exists; typically surfaced as 404.
Solutions
- Verify the batch part id via managementService.getBatchPart
- List batch parts of the parent batch
- Handle 404 as 'part finished or unknown id'
Defensive patterns
Strategy: try-catch
When it happens
Trigger: Thrown at modules/flowable-rest/src/main/java/org/flowable/rest/service/api/management/BatchPartBaseResource.java:38 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of flowable/flowable-engine@d6d39ce1c6 (2026-09-11).
Data as JSON: /api/errors/55dd3206f5e0c7a7.
Report an issue: GitHub.
Appendix: source
Thrown at modules/flowable-rest/src/main/java/org/flowable/rest/service/api/management/BatchPartBaseResource.java:38
import org.springframework.beans.factory.annotation.Autowired;
public class BatchPartBaseResource {
@Autowired
protected ManagementService managementService;
@Autowired(required=false)
protected BpmnRestApiInterceptor restApiInterceptor;
protected BatchPart getBatchPartById(String batchPartId) {
BatchPart batchPart = managementService.getBatchPart(batchPartId);
validateBatchPart(batchPart, batchPartId);
return batchPart;
}
protected void validateBatchPart(BatchPart batchPart, String batchPartId) {
if (batchPart == null) {
throw new FlowableObjectNotFoundException("Could not find a batch part with id '" + batchPartId + "'.", BatchPart.class);
}
if (restApiInterceptor != null) {
restApiInterceptor.accessBatchPartInfoById(batchPart);
}
}
}
View on GitHub (pinned to d6d39ce1c6)