Implementation of maker-checker flow

Today, I will give you one of the implementations of maker-checker workflow which I had adopted in my projects.

Introduction: 

It’s a quite common workflow in the industry especially followed in the banking domain where maker will create/update contents and the checker will approve the contents. This is considered to avoid mistakes while entering the records in the process.

Requirement:

  • We had the master data which needs to be created or updated through maker-checker flow. Then this data will be visible on the main sites for the users to view.
  • The User with the maker role will able to create and update the contents whereas with the checker role can approve/reject the newly available data.
  • Without checker’s approval, The contents should not be updated on the main master data.

Challenges:

  • If data is already approved and visible on the main site, then modifying/editing the contents will directly reflect on the main site.

Solutions:

Creating new contents were easy as it was not visible on the main website but the problem became slightly challenging where we needed to handle the scenario of data update.

We followed below strategy to handle this.

  • We created two tables for Master data.
    • a Temporary table where contents can be easily modified and created anytime.
    • an Approved Master Table where after the workflow data can be inserted or updated post approval in the temporary table.
  • we created common service which would update the data in the approved table on the basis of simple one to one mapping of temporary to master table.

For example,

  • employee_tmp and employee Table.
  • All modification will happen in the temporary table.
  • After the approval, Data would need to update from the temporary table to the actual table. This way master table will always get a new update after approval through maker-checker flow.

Hope this will people who want to implement this workflow in their projects.

Please do comment and ask if anything is missing or you have better solutions in your mind which others can learn.

Happy Learning!

Advertisements

2 thoughts on “Implementation of maker-checker flow

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.