• Maiquel Cabrera 6
  • NEWBIE
  • 25 Points
  • Member since 2015

  • Chatter
    Feed
  • 1
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 1
    Replies
On a Lightning Component, when calling an action on the Apex back-end using $A.enqueueAction(...), it takes a whileee to complete (up to 30 secs!). The action in the back-end is just a simple DML.

By reading the docs and inspecting the browser network debug logs, we understand this is because the actions are hold in a queue till some sort of poller/spooler thread processes it and dispatches these all together to the backed.

- Is there a way to execute actions inmediately, without enqueuing? Or control the frequency of the dispatching job?
- Or is it that we are something wrong, and $A.enqueueAction(...) is not the correct way to invoke an @AuraEnabled Apex method?

Thanks a lot!
On a Lightning Component, when calling an action on the Apex back-end using $A.enqueueAction(...), it takes a whileee to complete (up to 30 secs!). The action in the back-end is just a simple DML.

By reading the docs and inspecting the browser network debug logs, we understand this is because the actions are hold in a queue till some sort of poller/spooler thread processes it and dispatches these all together to the backed.

- Is there a way to execute actions inmediately, without enqueuing? Or control the frequency of the dispatching job?
- Or is it that we are something wrong, and $A.enqueueAction(...) is not the correct way to invoke an @AuraEnabled Apex method?

Thanks a lot!