Salesforce Certified Platform Developer II Practice Test - Questions Answers, Page 41
List of questions
Question 401
![Export Export](https://examgecko.com/assets/images/icon-download-24.png)
AW Computing (AWC) handles orders in Salesforce and stores its product inventory in a filed, inventory_c, on a custom object. product_c. When an order for a product_c placed, the Inventory_c field is reduced by the quantity of the order using an Apex trigger.
AWC wants to real-time inventory reduction for a product to be sent to many of its external systems, including some future systems the company is currently planning.
What should a developer add to the code at the placeholder to meet these requirements?
Question 402
![Export Export](https://examgecko.com/assets/images/icon-download-24.png)
An end user reports that a Lightning component is performing poorly.
Which two steps should to taken in production to investigate? Choose 2 answers
Question 403
![Export Export](https://examgecko.com/assets/images/icon-download-24.png)
Refer to the test method below:
The test method tests an Apex trigger that the developer knows will make a lot of queries when a lot of Accounts are simultaneously updated to be customers.
The test method fails at the Line 20 because of too many SOQL queries.
What is the correct way to fix this?
Question 404
![Export Export](https://examgecko.com/assets/images/icon-download-24.png)
Universal Containers (UC) has an ERP system that stores customer Information, When an Account is created in Salesforce, the ERP system's REST endpoint for creating new customers must automatically be called with the Account information. If the call to the ERP system falls, the Account should still be created. Accounts in the UC org are only created, one at a time, by users in the UC customer on-boarding department. What should a developer implement to make the call to the ERP system's REST endpoint?
Question 405
![Export Export](https://examgecko.com/assets/images/icon-download-24.png)
Universal Containers wants to notify an external system in the event that an unhandled exception occurs when their nightly Apex batch job runs.
What is the appropriate publish/subscribe logic to meet this requirement?
Question 406
![Export Export](https://examgecko.com/assets/images/icon-download-24.png)
Refer to the following code snippet:
A developer created a JavaScript function as part of a Lightning web component (LWC) that surfaces information about Leads by wire calling geyFetchLeadList whencertain criteria are met.
Which three changes should the developer implement in the Apex class above to ensure the LWC can display data efficiently while preserving security?
Choose 3 answers
Question 407
![Export Export](https://examgecko.com/assets/images/icon-download-24.png)
Universal Containers uses Salesforce to track orders in an order__c object.
The order = object has private organization-wide defaults. The order = object has a custom field, Quality_Controller_c, that is a Lookup to User and is used to indicate that the specified User is performing quality control on the order_ co.
What should be used to automatically give read only access to the User set in the Quality_Controller field?
Question 408
![Export Export](https://examgecko.com/assets/images/icon-download-24.png)
Universal Containers develops a Salesforce application that requires frequent interaction with an external REST API. To avoid duplicating code and improve maintainability, how should they implement the APL integration for code reuse?
Question 409
![Export Export](https://examgecko.com/assets/images/icon-download-24.png)
A developer is tasked with creating a Lightning web component that allows users to create a Case for a selected product, directly from a custom Lightning page. The input fields in the component are displayed in a non-linear fashion on top of an image of the product to help the user better understand the meaning of the fields.
Which two components should a developer use to implement the creation of the Case from the Lightning web component?
Choose 2 answers
Question 410
![Export Export](https://examgecko.com/assets/images/icon-download-24.png)
What are three reasons that a developer should write Jest tests for Lightning web components?
Choose 3 answers
Question