Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

As we cannot always guarantee the order of messages that are processed by the DCM Lists, it might happen that a case is first deleted and then a message is processed which tells the case (that is just deleted) is unlocked. What to do then? The DCM Lists application does not know that case (it was just deleted, no record is kept), so should it create the case then? Or should it ignore this message?

Delete flag

In order to solve this problem, the DCM Lists application does not delete cases immediately from the database. Instead, when a message is processed that leads to the removal of the case, the case is marked for deletion with a flag and a timestamp. The DCM Lists than further ignores this case, except when a message is processed that references this deleted case. Then the DCM Lists application knows that the case is deleted and can act accordingly.

Cleanup

As you can imagine, when you only mark cases for deletion but never actually remove these from the database, the database can grow quite quickly, depending on the number of cases that your application is processing. To make sure the database keeps a reasonable size and performance, a cleanup mechanism removes the cases marked for deletion from the database. This mechanism uses a interval at which it operates. The default is 2 hours. Every 2 hours, a cleanup job is triggered which removes all the cases marked for deletion that were marked at least 2 hours (the interval) ago. This means that messages belonging to a case that is deleted can be processed up to 2 hours after the case is deleted. After that, the case is gone and messages related to that case will result in an error.

...