Certified Platform Developer II Exam QuestionsBrowse all questions from this exam

Certified Platform Developer II Exam - Question 57


A developer needs to send Account records to an external system for backup purposes. The process must take a snapshot of Accounts as they are saved and then make a callout to a RESTful web service. The web service can only receive, at most, one record per call.

Which feature should be used to implement these requirements?

Show Answer
Correct Answer: BC

Queueable should be used because it allows for asynchronous processing and chaining of jobs, which is useful for sending each Account record individually to the external system. This aligns with the requirement that the web service can only receive one record per call. @future is less suitable because it does not allow job chaining, and Process Builder and Workflow are declarative tools that may require additional complexity through invocable methods and are not as efficient for this use case.

Discussion

10 comments
Sign in to comment
Dev_Bond_ZAOption: B
Feb 9, 2023

B Explanation "Takes a snapshot of accounts as they are" - this is all accounts - cannot be process builder for that reason, can not be future either, has to be queueable so you can queue each account one after the other.

SantoshtpdOption: C
Jul 22, 2021

C should be correct ,like Call the invocable method from process builder and from invocable method call the @future method and write your callout logic there in @future method.

nibbioOption: C
Nov 29, 2021

Process Builder + InvocableMethod marked with (callout=true)

moitamOption: B
Aug 24, 2023

I go with B for the same reason as @Dev_Bond_ZA

Pradip2021Option: A
Feb 19, 2021

It should be A, as it will call Restful web service and it is a slow process

lorenac2Option: C
Dec 27, 2022

This is correct as Salesforce prefers declarative first, so although @future would be used if it was a trigger, since PB is declarative, it would use this with an @InvocableMethod instead. Today, this would be done with a flow based trigger.

thneebOption: A
Feb 4, 2023

For me it is A. You need to write APEX code even if you use Process Builder. So I would directly code a APEX trigger and an @future method. If Process Builder would be aber to do direct API calls, like Flow it would be fine for me. If Flow would be a choice, then I would take Flow

cPickleOption: C
Apr 7, 2023

C is right. Queustion says "The web service can only receive, at most, one record per call.". A,B can call multiple record.

santo_ajOption: C
May 7, 2023

C is correct. Call the invocable method from process builder and from invocable method call the @future method and write your callout logic there in @future method.

AnjindalOption: B
May 22, 2024

correct ans is B