Why Do We Use Continuation?

Why Do We Use Continuation?

Continuation Class is used to make asynchronous callout using REST and SOAP services. Using this class, we can make a long running request from a Visualforce page to external systems, and can integrate our Visualforce pages with complex back end systems.

How do I use Continuation class in Salesforce?

Use the Continuation class to make callouts asynchronously to a SOAP or REST Web service. When the user hits Start Request button, the callout is made to the URL. Once the response is sent, processResponse method will be called.

What is Apex Continuation?

In Apex a Continuation refers to an asynchronous external callout (a callout that runs in the background). What this means is that the thread you opened when you made a callout becomes dormant while it's awaiting a response.

Alexander Ross
Author

Alexander Ross

Alexander Ross has covered the video game industry for a decade, writing deep dives on game design, esports tournaments, VR developments, and gaming culture.