Debug and Deployment Tools: 5% Flashcards
What is the Log Inspector and where do you find it?
Log Inspector can be found in the Developer Console. When you view the Logs panel and double-click a log, it will open it in the Log Inspector.
The Log Inspector is a context-sensitive execution viewer that shows the source of an operation, what triggered the operation and what occurred afterward. Use this tool to inspect debug logs that include database events, Apex processing, workflow and validation logic.
What does USER_DEBUG mean in the Execution log?
USER_DEBUG indicates the execution of a System.debug() statement
Can you directly create Apex code to run in a production environment?
Apex can never be directly created in a production environment
Where is Apex code unit tested?
Apex code is unit tested in a sandbox and in production when deployed
What is the Force.com Migration tool?
It is an ANT-based, extensible command line tool. It allows developers to use scripts for deploying Apex and is targeted for technical IT roles.
What is captured in the build.properties file?
The build.properties file contains the login details such as username, password and URLs for the target orgs. The login details are declared as property elements. This allows the developers to modify the login values any time.
If you are using a security token to log in from otuside the trusted IP range, paste the 25-digit token value at the end of the password.
What is captured in the build.xml file? (and what is the structure of it)
The build.properties file is included as the property file in the build.xml file.
This enables developers to override the default values for the local build environment.
Structure is as follows:
- Each project contains targets and each target can depend on other targets
- The target contains tasks to be performed as part of the automation script
When you run the Force.com Migration Tool you specify the name of the target that you want to build and the target runs various Force.com Migration Tool tasks as part of the build procedure.
What options are available to debug an Email Handler Class
Create a custom object to log any exceptions or debug statements.
Main reason: Developers do not have access to system log files in the context of an inbound email handler class
What are the 5 debugging levels?
info debug error warning critical
A developer is creating unit tests for code that makes SOAP web service callouts. The developer needs to insert some test data as a part of the unit tests setup
Choose 3 answers
A) Surround the callout with Test.startTest(), Test.stopTest()
B) Surround the data insertion with Test.startTest(), Test.stopTest()
C) Implement the WebServiceMock interface
D) Update code to call Test.setMock()
E) Implement the HttpCalloutMock interface
A, C and D
- Surround the callout with Test.startTest(), Test.stopTest()
- Implement the WebServiceMock interface
- Update code to call Test.setMock()
Which tool doesn't require a local file system for deploying metadata? A) Force.com IDE B) Workbench C) Change Sets D) Force.com Migration Tool
C) Change Sets
What is the recommended tool for scriptable deployments to sandbox and Developer Edition orgs? A) Force.com Migration Tool B) Force.com IDE C) Change Sets D) All of the above
A) Force.com Migration Tool
Managed packages can be used in which scenarios?
A) For a one-time setup
B) For non-namespaced orgs.
C) For customizations that are upgradeable and that you distribute to multiple orgs
D) For customizations that are not upgradeable
C) For customizations that are upgradeable and that you distribute to multiple orgs
Identify whether a Changeset or Force.com Migration Tool is the best option given a scenario:
- Straight sandbox to production Migrations
Changeset
Identify whether a Changeset or Force.com Migration Tool is the best option given a scenario:
- Development projects for which you need to populate a test environment with a lot of setup changes
Force.com Migration Tool
Identify whether a Changeset or Force.com Migration Tool is the best option given a scenario:
- Multistage release processes
Force.com Migration Tool