Uploaded image for project: 'Commons Chain'
  1. Commons Chain
  2. CHAIN-112

Add preProcess() and postProcess() apis to command interface

Attach filesAttach ScreenshotAdd voteVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • None
    • None
    • API
    • None

    Description

      Request to add preProcess and postProcess apis to command interface
      This would be useful as it would allow developers to break the logic as per the single responsibility principle.
      preProcess - to hold logic of initialization, few checks such as connection is fine etc..
      execute - main action
      postProcess - clean up logic, triggering events based on the outcome of execute

      preProcess and postProcess can be done in execute api itself, but sometimes its required to customize only some logic while desiring same action. In that case preProcess() and postProcess() apis can be overriden by the class implementing command interface or extending ChainBase classes

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            Unassigned Unassigned
            nikbhi15 Nikhil Bhide

            Dates

              Created:
              Updated:

              Slack

                Issue deployment