Discover millions of ebooks, audiobooks, and so much more with a free trial

From $11.99/month after trial. Cancel anytime.

Optimizing Salesforce Industries Solutions on the Vlocity OmniStudio Platform: Implementing OmniStudio best practices for achieving maximum performance
Optimizing Salesforce Industries Solutions on the Vlocity OmniStudio Platform: Implementing OmniStudio best practices for achieving maximum performance
Optimizing Salesforce Industries Solutions on the Vlocity OmniStudio Platform: Implementing OmniStudio best practices for achieving maximum performance
Ebook496 pages2 hours

Optimizing Salesforce Industries Solutions on the Vlocity OmniStudio Platform: Implementing OmniStudio best practices for achieving maximum performance

Rating: 0 out of 5 stars

()

Read preview

About this ebook

Salesforce Industries brings out-of-the-box solutions tailored to specific industries, making it easy for customers to install, configure, and slash their time-to-value. It stands as one of Salesforce's strategic pillars with the number of installations growing rapidly.
While customizing the out-of-the-box solutions can pose performance challenges, this book provides a fail-safe system with proven best practices, tools, and precise metrics to enhance performance and scalability for efficient outcomes.
Kicking off with an overview of the Salesforce Industries Vlocity platform and OmniStudio, you’ll explore the tools and techniques used to manage code and measure performance. Delving into performance optimization, you’ll uncover methods for improving performance in OmniStudio's Service Layer (Integration Procedures and DataRaptors) and Presentation Layer (OmniScripts and FlexCards). Further, the book will guide you through achieving maximum performance by leveraging best practices in both layers.
By the end of this book, you’ll have mastered the intricacies of Salesforce Industries on the Vlocity OmniStudio Platform, enhancing your skills to navigate and optimize tailored solutions effectively.

LanguageEnglish
Release dateApr 19, 2024
ISBN9781835461549
Optimizing Salesforce Industries Solutions on the Vlocity OmniStudio Platform: Implementing OmniStudio best practices for achieving maximum performance
Author

Dmitri Khanine

Dmitri Khanine is one of the most respected names in Oracle UCM. He one of the two people in the world who are recognized as leading community enthusiasts and advocates in the field of Content Management with a prestigious Oracle ACE award. He also runs the Independent Oracle UCM Knowledge Center. Dmitri is available for a limited number of training, speaking and consulting engagements. You can reach him at [email protected].

Related to Optimizing Salesforce Industries Solutions on the Vlocity OmniStudio Platform

Related ebooks

Enterprise Applications For You

View More

Related articles

Reviews for Optimizing Salesforce Industries Solutions on the Vlocity OmniStudio Platform

Rating: 0 out of 5 stars
0 ratings

0 ratings0 reviews

What did you think?

Tap to rate

Review must be at least 10 words

    Book preview

    Optimizing Salesforce Industries Solutions on the Vlocity OmniStudio Platform - Dmitri Khanine

    Cover.jpgPackt Logo

    Optimizing Salesforce Industries Solutions on the Vlocity OmniStudio Platform

    Copyright © 2024 Packt Publishing

    All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.

    Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author, nor Packt Publishing or its dealers and distributors, will be held liable for any damages caused or alleged to have been caused directly or indirectly by this book.

    Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.

    Portfolio Manager: Aaron Tanna

    Publishing Product Manager: Kushal Dave

    Book Project Manager: Deeksha Thakkar

    Senior Editor: Aditi Chatterjee

    Technical Editor: Vidhisha Patidar

    Copy Editor: Safis Editing

    Proofreader: Aditi Chatterjee

    Indexer: Manju Arasan

    Production Designer: Shankar Kalbhor

    DevRel Marketing Coordinators: Deepak Kumar and Mayank Singh

    First published: March 2024

    Production reference: 1280324

    Published by

    Packt Publishing Ltd.

    Grosvenor House

    11 St Paul’s Square

    Birmingham

    B3 1RB, UK

    ISBN 978-1-83546-847-0

    www.packtpub.com

    Contributors

    About the author

    Dmitri Khanine is a certified Vlocity and OmniStudio developer, trainer, and consultant based in Canada. He has spent the last 7 years of his over 25-year-long IT career focusing exclusively on Salesforce Industries.

    Dmitri combines training with hands-on development, creating industry apps with OmniStudio. This keeps his skills sharp and ensures he never runs out of fresh tips, tricks, and trade secrets.

    The recipe for Dmitri’s training success is simple. He gives students a complete view of the OmniStudio platform, followed by best practices and anti-patterns, and then takes it a step further by showing an actual percent improvement that each best practice is expected to bring.

    "There’s no point in repeating what can be easily found in online documentation in under 5 minutes, says Dmitri, It’s the tips and tricks that people are interested in."

    Dmitri is available for a limited number of training, speaking, and consulting engagements and can be contacted at [email protected].

    About the reviewers

    Sam Lienpanich is a recognized expert in Salesforce OmniStudio, specializing in Communications Cloud, CPQ, and Billing. With a robust background that intersects technology, innovation, and strategic implementation, Sam has dedicated his career to mastering and advancing the capabilities of Salesforce Industries and OmniStudio. His technical acumen and solution-oriented approach have set industry standards, particularly in his roles that span from a pivotal tenure at Oracle, Vlocity, and Salesforce. As the Salesforce Industries Global Lead at Sabio Group, a Premier Salesforce Partner, Sam leads the strategic development and execution of Salesforce Industries solutions, with a particular emphasis on telecommunications companies. He is highly regarded for his leadership in OmniStudio development, where his innovative methods establish benchmarks for scalable, efficient, and transformative solutions. Sam is dedicated to upholding and promoting best practices in OmniStudio development, ensuring that his team consistently delivers superior quality and groundbreaking results in their projects.

    I would like to express my appreciation to the author for crafting such an insightful and informative book. Heartfelt thanks to my family for their love and support during this review process. I am also grateful to Sabio Group for providing me with the opportunity to review this book, underscoring their commitment to continuous learning and professional growth.

    Rathin Mojumdar has over 24 years of experience as a seasoned Professional Services Leader and CRM professional. Throughout his career, he has successfully led CRM, data, and AI projects across diverse business environments, facilitating companies in achieving enhanced business agility and optimal customer satisfaction, and delivering niche business value propositions with a remarkable return on investment. His focus extends to assisting clients in their digital transformation journey, offering top-notch CRM/Industry Cloud solutions seamlessly integrated with ERP, mobile, social, and various other cloud applications. This integration results in a comprehensive omnichannel experience across both digital and traditional channels. His expertise encompasses a range of specialties, including CRM solutions, digital transformation, cloud architecture, solution design/IT strategy and framework development, managing complex implementations, building and overseeing cross-functional teams, system integration, and the formulation of enablement and transformation roadmaps.

    Table of Contents

    Preface

    Part 1: The Platform Overview

    1

    Understanding the Vlocity OmniStudio Platform

    Technical requirements

    What is OmniStudio?

    Digital Interaction Platform

    The Salesforce Industries Process Library

    Digital Experience Layer

    Service Management Layer

    Developer Experience Layer

    Summary

    2

    A Sample Application

    Technical requirements

    Hands-on lab – creating an OmniScript

    Creating an OmniScript

    Adding steps

    Creating a DataRaptor

    OmniScript preview

    Adding a FlexCard

    Adding a FlexCard to an OmniScript

    Summary

    Part 2: Getting to Know the Tools

    3

    Evaluating the Performance of an OmniStudio Implementation

    Technical requirements

    Measuring execution times in OmniStudio

    Execution times in DataRaptors

    Execution times in Integration Procedures

    Execution times in OmniScripts

    Exploring the OmniStudio Tracking Service

    Enabling tracking for OmniStudio

    Adding custom fields to event tracking

    Collecting stats and errors

    Salesforce debug logs

    Collecting debug logs in production

    Process Profiler in IDX Workbench

    Vlocity Error Log

    Summary

    4

    An Introduction to Load Testing

    Technical requirements

    Why and how to do load testing

    General considerations

    Salesforce Performance Assistant

    Running your load test

    Using Selenium for load testing

    Load testing with JMeter

    Summary

    5

    Tracking Code Changes and Deployment

    Technical requirements

    Using the out-of-the-box export and import tools

    Exporting Integration Procedures and OmniScripts

    Extracting metadata with the Vlocity Build tool

    Downloading the Vlocity Build tool

    Running the Vlocity Build tool

    Exporting Vlocity metadata

    Deploying Vlocity metadata

    Generating a Vlocity Manifest

    Using Salesforce’s SFDX tool

    Other OmniStudio configuration management tools

    Salesforce Vlocity Integration VS Code extension

    IDX Workbench

    CI tools

    Summary

    Part 3: Best Practices for Improving Performance

    6

    Options for Async Execution

    Technical requirements

    Why to consider async code execution

    Async configuration options for Integration Procedures

    Chainable

    Queueable Chainable setting

    Chain On Step

    How to call long-running Integration Procedures from the code

    Calling from Apex

    Calling from an LWC

    Async execution options in Apex

    Apex @future annotation

    Queueable Apex

    Batch Apex

    Scheduled Apex

    Summary

    7

    Understanding Caching

    Technical requirements

    What’s with all the caching?

    Manual caching options

    Caching in the Salesforce platform

    Caching options in DataRaptors

    Cache blocks in Integration Procedures

    Caching the response of the entire Integration Procedure

    Caching with the Lightning Wire service

    Custom caching on the client side

    Summary

    8

    Non-Selective Queries and Data Skew

    Technical requirements

    Case study – when an indexed field performs slower than a non-indexed one

    Selective and non-selective queries

    Optimizing queries with the Query Plan tool

    Understanding data skew

    Summary

    9

    Improving the Performance of the Service Layer

    Technical requirements

    Client or server side?

    DataRaptors or an Integration Procedure?

    Integration Procedure or server calls

    Comparing relationship notation and multiple extract steps

    Using multiple extract steps

    Using relationship notation

    Boosting performance by trimming the response JSON

    DataRaptors

    Integration Procedures

    How fast the Turbo Extract DataRaptor really is

    Summary

    10

    Improving the Performance of the Presentation Layer

    Technical requirements

    Performance impact of OmniScript best practices

    Performance impact of formulas on OmniScripts

    Performance impact of conditional views in OmniScripts

    Performance impact of merge fields in OmniScripts

    Measuring the performance of the Presentation Layer

    Measuring load times with LWC Debug Mode

    Measuring performance with Selenium

    Consider LWC lifecycle events

    Document generation options

    Summary

    11

    DataRaptor Formula Performance Considerations

    Technical requirements

    How fast are DataRaptor formulas?

    The QUERY function or another Extract?

    Limiting custom function payload size

    Summary

    12

    OmniStudio Performance Anti-Patterns

    Technical requirements

    DML, API, and Remote Action calls from Loop Block

    Better solutions

    Integration Procedure running after an error

    Better solutions

    Non-selective queries in DataRaptors

    Wildcards in Filter criteria

    Use of NULL values

    Use of EXCLUDES and NOT LIKE operators

    Summary

    Index

    Other Books You May Enjoy

    Preface

    OmniStudio is the engine behind customized, industry-specific offerings that run on the new part of the Salesforce platform called Salesforce Industries. It was originally built by Vlocity (who pioneered the concept of the Industry Cloud) and was acquired by Salesforce in 2020.

    While each industry has its common business processes, the OmniStudio platform along with the Industries data model offers the tools and components that support all types of industries, saving new and existing customers months and even years of development. Industries have really never been more important, says Salesforce Co-CEO Bret Taylor, highlighting that these offerings provide customers with quicker time to value.

    In 2022, Salesforce called Industries one of its three strategic growth pillars, along with Customer 360 and the company’s geographic expansion. The platform then continued to grow rapidly, and it is currently supporting 15 industries—up from 6 just 3 years ago at the time of the acquisition of Vlocity.

    However, as out-of-the-box solutions are customized and new apps are developed, clients often face performance and scalability issues. Just like with any new technology where the best practices and design patterns are still being refined, Salesforce Industries solutions built with OmniStudio may underperform or crumble under load.

    This book provides a foolproof system built on a set of proven best practices, tools, and specific metrics of improved performance and scalability. It will benefit administrators, developers, hands-on application architects, and business professionals involved with Salesforce Industries solutions.

    Beginning with the 1,000-foot view, zooming in on the performance and scalability issues of its key components, the book will provide critical insights, helping you deliver better-performing and more reliable OmniStudio apps.

    While some of these performance-related best practices are available, they are often scattered across different sources. The coherent system presented in this book, as well as the never-published performance assessments and anti-patterns, will help you achieve better results faster.

    Who this book is for

    This book offers technical guidance to IT professionals, administrators, developers, and hands-on application architects who are involved in Salesforce Industries projects. Whether looking to enhance existing Vlocity OmniStudio systems or embark on a new implementation journey, this book is your roadmap to better performance and scalability.

    While a basic understanding of the OmniStudio platform is sufficient to benefit from some of the chapters, administrator and developer-level experience would help you get the maximum benefit from this book.

    What this book covers

    Chapter 1

    , Understanding the Vlocity OmniStudio Platform, starts with the 1,000-foot view of Vlocity OmniStudio, which will drive home the overall vision behind the platform and how the components are designed to work together. This knowledge will make it easier to diagnose problems and improve the performance of your OmniStudio apps.

    Chapter 2

    , A Sample Application, offers a quick hands-on refresher, where you will be able to touch a lot of the OmniStudio moving parts so that you are better prepared for the chapters ahead.

    Chapter 3

    , Evaluating the Performance of an OmniStudio Implementation, provides a hands-on overview of the key tools and techniques for measuring the performance of OmniStudio components. These tools will come in handy before, during, and after the improvements are implemented.

    Chapter 4

    , An Introduction to Load Testing, continues where the previous chapter left off by looking at load testing and exploring the tools, tips, and best practices available for simulating real-life load on the system. This will help you measure the capacity, performance, and scalability of your OmniStudio apps and get ready to handle the expected customer demands.

    Chapter 5

    , Tracking Code Changes and Deployment, presents the tools and techniques that will make it easy to see, track, and reverse code and configuration changes in your system. These tools will allow you to adjust to better performance with complete peace of mind.

    Chapter 6

    , Options for Async Execution, discusses the best place to start by focusing on the area where a simple configuration change could produce massive performance improvement with just a few clicks. This chapter provides several options and step-by-step guidance for applying them.

    Chapter 7

    , Understanding Caching, reviews the second tool that can produce large performance gains quickly. In this chapter, we will explore the caching architecture of OmniStudio and the underlying Salesforce platform and how it can be applied to speed things up.

    Chapter 8

    , Non-Selective Queries and Data Skew, reviews a frequent reason for sub-standard performance in DataRaptors and Integration Procedures. While the first instinct usually is to blame OmniStudio, the issue may often originate in the underlying queries we’re running. In this chapter, you will find an example query on an indexed field that may run slower than one on a non-indexed field. We will then explore the reasons and look at the tools we can use to improve performance and prepare our apps for increasing data volumes.

    Chapter 9

    , Improving the Performance of the Service Layer, offers a few quick, sure-fire ways to spot and improve sub-standard performance in the OmniStudio Service layer: Integration Procedures and DataRaptors.

    Chapter 10

    , Improving the Performance of the Presentation Layer, explores the ways to spot and improve sub-standard performance in the OmniStudio Presentation layer: OmniScripts and FlexCards. This chapter also looks at the impact that some of the recommended Presentation layer best practices may have on our applications.

    Chapter 11

    , DataRaptor Formula Performance Considerations, reviews the out-of-the-box and custom Apex-based formula performance considerations and different options available to improve the performance of formulas in our DataRaptors and Integration Procedures.

    Chapter 12

    , OmniStudio Performance Anti-Patterns, introduces the concept of OmniStudio anti-patterns and reviews three common anti-patterns, the negative performance and scalability effects they may have on your apps, and ways to avoid them.

    To get the most out of this book

    To get the most out of this book, you should have some developer-level understanding of the Salesforce platform. Basic knowledge of Salesforce Objects, SOQL Queries, and some understanding of Apex and governor limits is assumed as these are foundational for developing and improving the performance of applications built on the Salesforce platform.

    Some developer-level familiarity with OmniStudio is required to get the most out of Part 3 of the book. Furthermore, a basic understanding of HTML and Chrome Developer Tools would be beneficial to get the most out of Chapter 10

    , Improving the Performance of the Presentation Layer.

    There are many short code snippets in this book provided solely for demonstration purposes, and you do not need to execute them directly to understand them. That said, it is recommended to practice the topics discussed in the book in a sandbox with a recent version of OmniStudio installed.

    The following is the software covered in the book:

    Salesforce platform/Sales Cloud

    Salesforce Industries/OmniStudio

    You will find a list of the supported browsers and devices at https://help.salesforce.com/s/articleView?id=sf.getstart_browsers_sfx.htm&type=5

    Note

    As OmniStudio is still very new, Salesforce is actively updating documentation as we speak and some of the links we have placed in this book may no longer work when you will be reading it. If this happens, please use the search feature in Salesforce documentation.

    Disclaimer on images

    Some images in this title are presented for contextual purposes, and the readability of the graphic is not crucial to the discussion. Please refer to our free graphic bundle to download the images. You can download the images from https://static.packt-cdn.com/downloads/9781835468470_ColorImages.pdf

    Conventions used

    There are a number of text conventions used throughout this book.

    Code in text: Indicates code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles. Here is an example: To call an Integration Procedure from Apex, use the runIntegrationService method of the IntegrationProcedureService class.

    A block of code is set as follows:

    Map ipOutput =

    (Map ) omnistudio.IntegrationProcedureService

       .runIntegrationService(

         'sample_IPCalculate',

         new Map (),

         new Map ()

       );

    Any command-line input or output is written as follows:

    error: You have uncommitted work pending. Commit or rollback before calling out

    Bold: Indicates a new term, an important word, or words that you see onscreen. For instance, words in menus or dialog boxes appear in

    Enjoying the preview?
    Page 1 of 1