Uploaded image for project: '[Read Only] - Hippo Site Toolkit 2'
  1. [Read Only] - Hippo Site Toolkit 2
  2. HSTTWO-2914

Provide proper support for using DocumentWorkflow with the WorkflowPersistenceManager

    XMLWordPrintable

Details

    • Improvement
    • Status: Closed
    • Normal
    • Resolution: Fixed
    • None
    • 2.28.00
    • None
    • Sprint 76, Sprint 77

    Description

      The current WorkflowPersistenceManagerImpl class still uses and exposes the now deprecated ReviewedActionsWorkflow (and friends).
      Because it is currently impossible to determine from the usage of the WorkflowPersistenceManager to know if either (still) the deprecated workflow or the new DocumentWorkflow should be used and exposed (through the WorkflowCallbackHandler), a new QualifiedWorkflowCallbackHandler interface (extending WorkflowCallbackHandler) will be provided and the current WorkflowCallbackHandler deprecated.
      The new QualifiedWorkflowCallbackHandler will add one method: Class<? extends> Workflow getWorkflowType(), which then can be used by the WorkflowPersistenceManager to determine if it should use the DocumentWorkflow or not.
      Projects using the HST WorkflowPersistenceManager still can use the current solution but will be advised to upgrade their usage with the new QualifiedWorkflowCallbackHandler.

      As a convenience, an abstract BaseWorkflowCallbackHandler class will be provided which will automatically take care of implementing the above getWorkflowType() method,
      and the (minimal) upgrade then only requires extending this class instead of implementing the now deprecated WorkflowCallbackHandler.
      Of course, a proper upgrade when currently using ReviewedActionsWorkflow or related deprecated 'friends', also should update the requested Workflow (type) to DocumentWorkflow.

      We have examples of these WorkflowCallbackHandlers in gogreen and the testsuite: I will fully upgrade the gogreen usages (separate issue), but leave the testsuite as 'assurance' that the old usages also remain working.

      Attachments

        Issue Links

          Activity

            People

              jsheriff Junaidh Kadhar Sheriff
              adouma Ate Douma (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: