Recently while working on a customer requirement, we came across a scenario where we needed to trigger a plugin on change of Business Process Flow stages. So, in the pursuit of finding a solution, we came across workflow and process stage entities, but they were not very useful in this scenario. Our requirement was to trigger the plugin on the Business Process Flow stage change of an Employee entity. So, we tried writing a plugin for the update of an Employee entity. There’s one field “stageid” on every entity on which a Business process flow is configured. We thought on the change of the Business Process Flow stage this field might be getting updated with the Id of the current active stage, which we can further use to fulfill our requirement. But to our disappointment, this field is now deprecated and thus we are left empty-handed.
Further investigation brought light to the reality i.e., for every Business Process Flow, a subsequent Entity gets created in…