I have a trigger which run on insert of a parent record. The working for trigger is like when parent is inserted all the child related to parent get inserted and when child get inserted all the grand child get inserted, it goes till level 4. After all the records get inserted it me result up to 500 to 1000 records get inserted in a single transition. My trigger in recursive so around 50 SOQL getting executed. To break this trigger we stop the trigger to level 2, i.e when parent and child get inserted stop the trigger and do not insert grand child or grand grand child. we are creating parent from VF page so after the parent and child is getting inserted one transition and on a button click update a field on child records and it will generate all the grand child and its child. For overcoming the issue of limit we are making 4 different remote action from VF page. From @remoteaction we are making a call to @future method.
My question is:
- Do we need to have call to @future method or we need to have all the code in @remoteaction itself?
- Does @future method make any difference?`