Denny,
Gateway is not persisted, it does not have id in the runtime.
Each EngineConfiguration (ProcessEngineConfiguration too) can have its own idGenerator (org.flowable.common.engine.impl.AbstractEngineConfiguration#idGenerator).
So just set your own idGenerator impl. for the process engine.
It helps for executions/processes, cases, etc., but it does not work for e.g. tasks because they do not have their own engine configuration.
Have a look on org.flowable.common.engine.impl.db.DbSqlSession#insert
I see two possibilities there:
- implement your own DbSqlSession - you can handle anything there
- implement custom TaskDataManager (based on
org.flowable.task.service.impl.persistence.entity.data.impl.MybatisTaskDataManager
) to handle task Ids.
Regards
Martin