Category: Development

Debugging For Salesforce Developers

A bug has been reported in production and there’s no obvious path to the problem. What are you going to do? A build process is failing and the errors make no sense. What are you going to do? A report is showing you things in the data that just shouldn’t happen. What are you going to do?

Continue reading “Debugging For Salesforce Developers”

Using Lazy Evaluation to Write Salesforce Apex Code Without For-Loops

Functions or for-loops?

A developer working in Javascript has access to some really convenient functions on Arrays. Functions like filter() and map()  can avoid the need to write for-loops. Is this actually a good thing? Can we write Apex this way?

Continue reading “Using Lazy Evaluation to Write Salesforce Apex Code Without For-Loops”

Performance Testing of Process Builder vs Apex

The choice between writing custom Apex code or using declarative tools in Salesforce has always been a difficult one to make. Process Builder is capable of more than Workflow was, but it came at a big performance cost. In this article, Roger Mitchell measures that performance cost again. And it looks like things have improved considerably since 2016. Continue reading “Performance Testing of Process Builder vs Apex”

Patterns in Apex: Dependency Injection, Strategy, and Decorator

When you start out in Salesforce development, there seems to be little need for software design patterns. Perhaps because development starts with little triggers doing this and that in a few lines of code. But, as soon as the requirements, codebase, and team-size grow, then the advantages of patterns and other software engineering practices kick in. Continue reading “Patterns in Apex: Dependency Injection, Strategy, and Decorator”

Never mind the half-baked solution, what was the problem? (The X Y Problem)

As a consultant, and as a developer, one of the most useful things you can do is to take a step back. If someone asks you a question about a detail of a solution they are working on, it’s often worth finding out what problem they were originally trying to solve. Continue reading “Never mind the half-baked solution, what was the problem? (The X Y Problem)”