Stale ProcessDefinition cache when modifying the suspensionState

Description

When running in a distributed environment we're having issues with the suspensionState of ProcessDefinitions being stale when read from the DeploymentCache. If NodeA updates the suspensionState of a definition, when NodeB reads it from its cache it will be out of date. One possible solution would be for us to implement a distributed cache, but that seems like overkill for this simple bug. Another possible workaround would be to always hit the database for operations that depend on the suspensionState (or have a combination).
We think that a better solution would be to not cache mutable state in the first place. So that would mean not storing ProcessDefinitionEntity in the cache (just BpmnModel and Process).

More discussion on this issue on the forums here.

Environment

None

Assignee

Joram Barrez

Reporter

Logan Chadderdon

Labels

None

Components

Fix versions

Affects versions

Priority

Medium
Configure