Skip to main content

Difference between Asynchronous Plugin and Workflows in MSCRM


So many times I have been asked a question from my colleagues, 
What is the difference between Async Plugin and Workflow, Since both are Asynchronous But What is the actual difference between them and When should i use Workflow and When should I use Async Plugin ?

Answer :
My Answer is always "Depends", the right approach is determined by the Characteristics of the task that you are trying to accomplish.


 Following Matrix show the difference between the same :



          Requirement

Use Plug-in

Use Workflow

Needs a synchronous action to happen before or after an event occurs
Or
Need to perform a task that has to completed within 2 Sec




Yes


              No

 The logic needs to be executed while offline

Yes

No
Needs elevation of privileges (impersonation)
Or
Perform data operations on behalf of another system user



Yes


No
Needs to execute on events other than assign, create, update, set state

Yes

No
The process/logic may take a long time to complete or will be a persistent process (multiple long running steps)

No

Yes

End users will need to modify the process logic

            No

Yes
                                         Child sub processes will be triggered

No

Yes

Comments

Popular posts from this blog

Asp.net- Encrypt and Decrypt connection strings in web.config file

In this article I will explain how to encrypt or decrypt connectionStrings in web.config file using asp.net. If we are using applications in our internal servers with security then it’s ok if we deploy our applications in shared host environment then we have chance to arise security problems to avoid these problems asp.net 2.0 provided built in protected configuration model functionality to encrypt or decrypt few sections of web.config file those are RSAProtectedConfigurationProvider :   This is default provider and uses the RSA public key encryption algorithm to encrypt and decrypt data. DataProtectionConfgurationProvider : This provider uses windows data protection application programming interface to encrypt and decrypt the data. The encrypting and decrypting of connection strings in web.config file will do by using aspnet_regiis.exe  command line tool and  code behind . First Method : First we will do encryption and decryption using  aspnet...

CRM Automate build Solution using Powershell commands

In CRM if there is any solution movement from other enviornment like DEV,PROD,STG we use to export the solution and import the solution to the respective environment by logging into MS Dynamics CRM. This will tends to extra effort to do manually for developers or release managers. So what if release user or test user can build and deploy the Solution deployment without CRM intervention(CRM loggin in) We need to do some automate build and deployment. In this article i write about how Import/Export solution automate to the various environment without intervention of logging into MS Dynamics CRM. XRM CI Framework,this is one tool use to automate the build in CRM       Below link is for download the XRM CI Framework https://xrmciframework.codeplex.com/releases/view/125516 Download and extract the ZIP file . First HelloWorld example “WhoAmIRequest” 1.Open "Powershell" and "Run as a Administrator" 2.Navigate to Extrac...

Auto number generation using C# and SQL

Auto number generation using C# and SQL ------------------------------------------------------ Req :  Create a Autonumber for Particular Application form(Eg:Order or Quote) Approach : ------------- 1.Create a Separate autonumber configuration table which looks like below AutoNumConfig table --------------------------   AutoNumberId  AutoNumber   FormNameorFormId   -------------------------------------------    1             ORD-0002     Order or 1066    2             QUO-0002     Quote or 1067 2.Create Transaction table for Application  Form(Eg:Order/Quote) which looks like below OrderTable -------------- OrderId   OrderName  OrderAutoNum -------------------------------------------   1       Spartan      ORD-0001   2       Xamarin      ORD-0002 QuoteT...