Hiring guide for Apex Engineers

Apex Developer Hiring Guide

Apex is a proprietary, Java-like programming language developed by Salesforce.com. It was introduced in 2006 to allow developers to execute flow and transaction control statements on the Salesforce platform server in conjunction with calls to the API (Application Programming Interface). As an integrated part of the Salesforce platform, Apex allows developers to add business logic to most system events, including button clicks, related record updates, and Visualforce pages. Apex code can be initiated by web service requests and from triggers on objects. Its syntax resembles Java and acts like stored procedures (Salesforce Developers Documentation).

Ask the right questions secure the right Apex talent among an increasingly shrinking pool of talent.

First 20 minutes

General Apex app knowledge and experience

The first 20 minutes of the interview should seek to understand the candidate's general background in Apex application development, including their experience with various programming languages, databases, and their approach to designing scalable and maintainable systems.

What are the different data types supported in Apex?
Apex supports primitive data types like Integer, Double, Long, Date, Datetime, String, ID, and Boolean. It also supports collection types like Lists, Sets, and Maps, and user-defined types like classes, interfaces, and enums.
How would you write a basic trigger in Apex?
A basic trigger in Apex would look like this: 'trigger AccountTrigger on Account (before insert) { for(Account a : Trigger.new) { // business logic here } }'. This trigger fires before new Accounts are inserted into the database.
Describe the difference between a SOQL and SOSL query.
SOQL (Salesforce Object Query Language) is used to query records from single objects while SOSL (Salesforce Object Search Language) is used to search text, email, and phone fields for multiple objects.
What are governor limits in Apex?
Governor limits control the amount of data or number of records you can handle in a single transaction to ensure no single script or process monopolizes shared resources.
How would you handle exceptions in Apex?
In Apex, exceptions are handled using try, catch, and finally blocks. You can also throw custom exceptions with the 'throw' keyword.
The hiring guide has been successfully sent to your email address.
Oops! Something went wrong while submitting the form.

What you’re looking for early on

Has the candidate demonstrated a deep understanding of Apex syntax and structure?
Is the candidate able to articulate complex concepts clearly?
Did the candidate show experience with version control systems like Git?
Has the candidate shown problem-solving abilities during the interview?

Next 20 minutes

Specific Apex development questions

The next 20 minutes of the interview should focus on the candidate's expertise with specific backend frameworks, their understanding of RESTful APIs, and their experience in handling data storage and retrieval efficiently.

What is the purpose of the 'final' keyword in Apex?
The 'final' keyword is used to prevent a method or variable from being overridden or modified.
Describe the difference between a future method and a queueable method in Apex.
Future methods are used for fire-and-forget operations and cannot be chained together or monitor their progress. Queueable methods, on the other hand, can be chained together and allow you to track their progress.
How would you perform a DML operation on multiple records in Apex?
You can perform DML operations on multiple records by using a list of sObjects. For example: 'List accts = [SELECT Id FROM Account LIMIT 5]; delete accts;'.
What are the different types of collections in Apex?
Apex has three types of collections: Lists, Sets, and Maps. Lists are ordered collections, Sets are unordered collections of unique elements, and Maps are collections of key-value pairs.
How would you use a Map collection in Apex?
A Map collection can be used to store and retrieve data as key-value pairs. For example: 'Map acctMap = new Map([SELECT Id, Name FROM Account]);'.
The hiring guide has been successfully sent to your email address.
Oops! Something went wrong while submitting the form.

The ideal back-end app developer

What you’re looking to see on the Apex engineer at this point.

At this point, a skilled Apex engineer should demonstrate strong problem-solving abilities, proficiency in Apex programming language, and knowledge of software development methodologies. Red flags include lack of hands-on experience, inability to articulate complex concepts, or unfamiliarity with standard coding practices.

Digging deeper

Code questions

These will help you see the candidate's real-world development capabilities with Apex.

What does the following Apex code do?
public class HelloWorld {
 public void printHelloWorld() {
 System.debug('Hello, World!');
 }
}
This code defines a class named 'HelloWorld'. Inside this class, there is a method named 'printHelloWorld' that prints 'Hello, World!' to the debug log when called.
What will be the output of the following Apex code?
Integer x = 5;
Integer y = 10;
System.debug(x + y);
The output of this code will be 15. It declares two integers, x and y, assigns them the values 5 and 10 respectively, and then prints the sum of x and y to the debug log.
What does the following Apex code do?
List numbers = new List{1, 2, 3, 4, 5};
numbers.remove(2);
System.debug(numbers);
This code creates a list of integers, removes the third element from the list (since list indices start at 0), and then prints the modified list to the debug log. The output will be (1, 2, 4, 5).
What does the following Apex code do?
public class MyRunnable implements System.Runnable {
 public void run() {
 System.debug('Running in a new thread.');
 }
}
System.enqueueJob(new MyRunnable());
This code defines a class that implements the System.Runnable interface and enqueues it to run in a separate thread. The 'run' method of the class prints 'Running in a new thread.' to the debug log.

Wrap-up questions

Final candidate for Apex Developer role questions

The final few questions should evaluate the candidate's teamwork, communication, and problem-solving skills. Additionally, assess their knowledge of microservices architecture, serverless computing, and how they handle Apex application deployments. Inquire about their experience in handling system failures and their approach to debugging and troubleshooting.

Describe the difference between a class and an interface in Apex.
A class is a blueprint from which individual objects are created. An interface, on the other hand, is a reference type in Apex, similar to a class, that can contain only abstract methods.
What is the purpose of the 'static' keyword in Apex?
The 'static' keyword is used to declare class variables and methods, which can be accessed without instantiating the class.
How would you use batch Apex for large data operations?
Batch Apex allows you to define a single job that can be broken up into manageable chunks, where each chunk can be processed separately. It is particularly useful when dealing with large data volumes.

Apex application related

Product Perfect's Apex development capabilities

Beyond hiring for your Apex engineering team, you may be in the market for additional help. Product Perfect provides seasoned expertise in Apex projects, and can engage in multiple capacities.