You need to sign in to do that
Don't have an account?

How to avoid recursion of triggers in asynchronous apex?
Hello there,
I have triggers on Contact and User objects. Contact trigger updates user record in future method. The user trigger on the other hand updates related contact in future method.
As future method is an asynchronous apex, I cannot track the execution using static variable. Is there any standard way that my scenario can be handled?
Thanks in advance.
I have triggers on Contact and User objects. Contact trigger updates user record in future method. The user trigger on the other hand updates related contact in future method.
As future method is an asynchronous apex, I cannot track the execution using static variable. Is there any standard way that my scenario can be handled?
Thanks in advance.
Running the future method from another method is impossible. As per Salesforce documentation, Please, check the "Apex Jobs" logs(Setup -> Monitor -> Jobs -> Apex Jobs) for any errors.
For solve the problem you can try to add a condition. If it helped you, then please select it the best answers it will help outer also.
Thank,
Alex
All Answers
Running the future method from another method is impossible. As per Salesforce documentation, Please, check the "Apex Jobs" logs(Setup -> Monitor -> Jobs -> Apex Jobs) for any errors.
For solve the problem you can try to add a condition. If it helped you, then please select it the best answers it will help outer also.
Thank,
Alex