Activiti/Activiti · error · ActivitiException
only provided id generation allowed for properties
Error message
only provided id generation allowed for properties
What it means
PropertyEntityImpl.setId is deliberately unassignable: property rows (ACT_GE_PROPERTY, e.g. next.dbid, schema.version) have their id (NAME_) assigned by the factory that creates them, so external setId calls are rejected with ActivitiException. The id generation for properties is 'provided' only, meaning it comes from PropertyEntity.create... constructors.
Solutions
- Do not change the id: create a new PropertyEntity via PropertyEntity.createByName(name) / createAndInsert and delete the old row instead.
- Update the property's value with PropertyEntityManager.updateProperty(name, value), leaving the name/id untouched.
- If generic entity code calls setId, exclude PropertyEntity from that path.
Example fix
// before
PropertyEntity prop = ...;
prop.setId("next.dbid.v2"); // throws
// after
propertyEntityManager.updateProperty("next.dbid", newValue); Defensive patterns
Strategy: try-catch
Validate before calling
if (entity instanceof PropertyEntity) {
// ids are factory-provided; never call setId
} Type guard
null
Try / catch
try {
prop.setId(newName);
} catch (ActivitiException e) {
// rename via new property entity instead
} Prevention
- Treat PropertyEntity ids as immutable; change values only.
- Exclude PropertyEntity from generic entity-hydration code that calls setId.
- Use PropertyEntityManager.updateProperty(name, value) for mutations.
When it happens
Trigger: Calling setId("name") on a PropertyEntity obtained from PropertyEntityImpl or fetched from the engine, e.g. while trying to rename or re-key a property row.
Common situations: Custom engine extensions or migrations that patch properties via the entity API; framework mapping code (e.g. reflection-based hydration or ORM tooling) that generically calls setId on all entities.
Understand the failure class
Background: UnsupportedOperationException and "is not supported" errors: when a library deliberately refuses a call — this error's family across 30 libraries.
Related errors
- Ad-hoc sub process has running child executions that need…
- can't clear configuration beans
- can't search values in configuration beans
- Cannot assign a groupId to a task assignment that already…
- Cannot assign a groupId to a task assignment that already…
AI-assisted analysis of Activiti/Activiti@56435b1a97 (2026-09-09).
Data as JSON: /api/errors/026a9e554e48542a.
Report an issue: GitHub.
Appendix: source
Thrown at activiti-core/activiti-engine/src/main/java/org/activiti/engine/impl/persistence/entity/PropertyEntityImpl.java:59
public String getValue() {
return value;
}
public void setValue(String value) {
this.value = value;
}
public String getId() {
return name;
}
public Object getPersistentState() {
return value;
}
public void setId(String id) {
throw new ActivitiException("only provided id generation allowed for properties");
}
// common methods //////////////////////////////////////////////////////////
@Override
public String toString() {
return "PropertyEntity[name=" + name + ", value=" + value + "]";
}
}
View on GitHub (pinned to 56435b1a97)