SlideShare a Scribd company logo
1 of 21
Download to read offline
● Who is CodeScience?
● Introduction
● Error handling in ISV Applications
● New In Spring ‘21
● Using these events in packages
● Demo
● Recap
Agenda
This is an image placeholder for an image.
Please size accordingly.
● Founding partner of the Salesforce Product
Development Organization (PDO) Program since
2008 - named Master PDO in 2017
● PDO Program provides app development services
to ISVs for the Salesforce AppExchange
● Partner with clients in various industries to assist
in building over 300 apps on the AppExchange
● From design to build to implementation, we
support through the full lifecycle
Who is CodeScience
Client success: 10% of the AppExchange
CodeScience client focus:
Today’s Speakers:
Rob Davis
Technical Architect
CodeScience
Error Handling In ISV Applications
Why do errors occur?
● We aren’t perfect, sometimes there are coding mistakes
● Subscribers often misconfigure applications. Missing permissions,
credentials, etc.
● Subscribers may build logic, automation, validations, etc that
interfere with the normal function of applications
● Subscriber environments may present unanticipated challenges,
such as 50M+ accounts, hundreds of Process Builders, inefficient
custom code, elaborate sharing models
● Sometimes, errors just happen
Reactive Error Handling
● A subscriber notices some functionality is not working, such as “An
Unexpected Error Has Occurred”, Apex jobs are in error state, data is
not correct, etc.
● They reach out to your customer support with this information, and
you have to help diagnose and fix the issue
● This is time-consuming, costly, and can lead to a loss of trust if it
happens often
Proactive Error Handling
● You attempt to catch errors that you anticipate, and handle them
appropriately
● You attempt to catch anything unexpected, with a few options:
○ Store in a “Log” object with visibility to subscriber, and possible trigger logic
○ Emit an event that can be subscribed to
○ “Phone home” with the information (with explicit subscriber consent)
○ Use FMA FeatureParameterInteger to log error counts
○ Flag “problem” records to exclude from processing
○ Implement a retry mechanism
New in Spring ‘21
New in Spring ‘21
Use BatchApexErrorEvent Triggers to Monitor ISV Applications
● Include BatchApexErrorEvent triggers in your managed package to
monitor the health of batch jobs and take necessary corrective action
without any post-installation steps
● This change applies to Lightning Experience and Salesforce Classic
● The BatchApexErrorEvent object represents a platform event
associated with a failing batch Apex execution
BatchApexErrorEvent
● This is a standard Salesforce event, which can be emitted from Batch
Apex Classes that encounter errors
● This event can be subscribed to just like normal Platform Events, as
well as being able to handle the events with triggers
● It was released in Winter ‘19, but a trigger handler could not be
packaged until Spring ‘21
● It includes information such as job id, error type, record ids being
processed, etc.
● It is triggered on any batch error, including “uncatchable” errors,
such as limit exceptions
Using These Events In Packages
Basic Setup
What Information do you get?
● What job id was running, from which you can get Apex class &
namespace
● The type of exception
● What IDs of the records that were being processed
● The exception message
● The Phase
● The stack trace*** (caveat on next slide)
What are the limitations/concerns?
● No stack trace is available when running from a managed package
● This is a standard event, so you get all subscriber and other package
events as well
● You should limit your error processing to just Apex classes in your
namespace for both data quality & security reasons
● You still don’t get direct access to the error information, and need
consent from your customers to send it to you.
● The JobScope (record ids) is limited to 40k characters (~2100 record
ids and commas), after which point it will be truncated and
DoesExceedJobScopeMaxLength set to true
Demo
In Summary...
● This new Spring ‘21 feature fills in a gap of batch error handling
● This should be used in conjunction with other available
error-handling, such as catching DML errors in the batch and
flagging problem records for follow-up
● You could log this information, subscribe to it, phone home, retry the
batch, flag problematic records, increase error counts in FMA…
● All of these options should increase the resiliency of your solution,
and make debugging issues easier
Contact Us:
Thank You
info@codescience.com
References
● Salesforce Blog Post -
https://developer.salesforce.com/blogs/2019/01/building-a-batch-retry
-framework-with-batchapexerrorevent.html
● Developer documentation -
https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/ape
xcode/apex_batch_platformevents.htm
● Technical Documentation -
https://developer.salesforce.com/docs/atlas.en-us.platform_events.me
ta/platform_events/sforce_api_objects_batchapexerrorevent.htm

More Related Content

What's hot

Salesforce World Tour 2016 : Lightning Out : Components on any Platform
Salesforce World Tour 2016 : Lightning Out : Components on any PlatformSalesforce World Tour 2016 : Lightning Out : Components on any Platform
Salesforce World Tour 2016 : Lightning Out : Components on any Platformandyinthecloud
 
“FME Hackathon 2020: Connections” User Judging
“FME Hackathon 2020: Connections” User Judging“FME Hackathon 2020: Connections” User Judging
“FME Hackathon 2020: Connections” User JudgingSafe Software
 
Introduction to Analytics Cloud
Introduction to Analytics CloudIntroduction to Analytics Cloud
Introduction to Analytics CloudMohith Shrivastava
 
Getting Certified - proven tips for success (French Touch Dreamin)
Getting Certified - proven tips for success (French Touch Dreamin)Getting Certified - proven tips for success (French Touch Dreamin)
Getting Certified - proven tips for success (French Touch Dreamin)Samuel De Rycke
 
Benefits of codeigniter in web development
Benefits of codeigniter in web developmentBenefits of codeigniter in web development
Benefits of codeigniter in web developmentARKA Softwares
 
Api functional monitoring -9th October 2021
Api functional monitoring -9th October 2021Api functional monitoring -9th October 2021
Api functional monitoring -9th October 2021AnuragSharma900
 
Three Steps for Building an Integrated BPM Application
Three Steps for Building an Integrated BPM ApplicationThree Steps for Building an Integrated BPM Application
Three Steps for Building an Integrated BPM ApplicationBonitasoft
 
Personalized, Powerful, Easy-to-change Business Applications
Personalized, Powerful, Easy-to-change Business ApplicationsPersonalized, Powerful, Easy-to-change Business Applications
Personalized, Powerful, Easy-to-change Business ApplicationsBonitasoft
 
Kochi Mulesoft Meetup #4
Kochi Mulesoft Meetup #4Kochi Mulesoft Meetup #4
Kochi Mulesoft Meetup #4sumitahuja94
 
Ordina SOFTC Presentation - SharePoint - Automated scripted deployment
Ordina SOFTC Presentation - SharePoint - Automated scripted deploymentOrdina SOFTC Presentation - SharePoint - Automated scripted deployment
Ordina SOFTC Presentation - SharePoint - Automated scripted deploymentOrdina Belgium
 
#2 connected apps_calicut_31_july
#2 connected apps_calicut_31_july#2 connected apps_calicut_31_july
#2 connected apps_calicut_31_julyJohnMathewPhilip
 
Batch Processing with Mule 4
Batch Processing with Mule 4Batch Processing with Mule 4
Batch Processing with Mule 4NeerajKumar1965
 
Helping agencies to build software business
Helping agencies to build software businessHelping agencies to build software business
Helping agencies to build software businessMaharajan Valluvan
 
Rollup Summary Trigger for Lookup Relationship Salesforce #Salesforce #ApexTr...
Rollup Summary Trigger for Lookup Relationship Salesforce #Salesforce #ApexTr...Rollup Summary Trigger for Lookup Relationship Salesforce #Salesforce #ApexTr...
Rollup Summary Trigger for Lookup Relationship Salesforce #Salesforce #ApexTr...Amit Singh
 
7-SilverlightFireStarter-Toolkit and Controls - Marco Matos
7-SilverlightFireStarter-Toolkit and Controls - Marco Matos7-SilverlightFireStarter-Toolkit and Controls - Marco Matos
7-SilverlightFireStarter-Toolkit and Controls - Marco MatosMithun T. Dhar
 
#1 Calicut MuleSoft Meetup - Introduction to Enterprise Integration and MuleSoft
#1 Calicut MuleSoft Meetup - Introduction to Enterprise Integration and MuleSoft#1 Calicut MuleSoft Meetup - Introduction to Enterprise Integration and MuleSoft
#1 Calicut MuleSoft Meetup - Introduction to Enterprise Integration and MuleSoftJohnMathewPhilip
 

What's hot (19)

Salesforce World Tour 2016 : Lightning Out : Components on any Platform
Salesforce World Tour 2016 : Lightning Out : Components on any PlatformSalesforce World Tour 2016 : Lightning Out : Components on any Platform
Salesforce World Tour 2016 : Lightning Out : Components on any Platform
 
“FME Hackathon 2020: Connections” User Judging
“FME Hackathon 2020: Connections” User Judging“FME Hackathon 2020: Connections” User Judging
“FME Hackathon 2020: Connections” User Judging
 
Introduction to Analytics Cloud
Introduction to Analytics CloudIntroduction to Analytics Cloud
Introduction to Analytics Cloud
 
Getting Certified - proven tips for success (French Touch Dreamin)
Getting Certified - proven tips for success (French Touch Dreamin)Getting Certified - proven tips for success (French Touch Dreamin)
Getting Certified - proven tips for success (French Touch Dreamin)
 
Benefits of codeigniter in web development
Benefits of codeigniter in web developmentBenefits of codeigniter in web development
Benefits of codeigniter in web development
 
Api functional monitoring -9th October 2021
Api functional monitoring -9th October 2021Api functional monitoring -9th October 2021
Api functional monitoring -9th October 2021
 
Three Steps for Building an Integrated BPM Application
Three Steps for Building an Integrated BPM ApplicationThree Steps for Building an Integrated BPM Application
Three Steps for Building an Integrated BPM Application
 
Personalized, Powerful, Easy-to-change Business Applications
Personalized, Powerful, Easy-to-change Business ApplicationsPersonalized, Powerful, Easy-to-change Business Applications
Personalized, Powerful, Easy-to-change Business Applications
 
Kochi Mulesoft Meetup #4
Kochi Mulesoft Meetup #4Kochi Mulesoft Meetup #4
Kochi Mulesoft Meetup #4
 
Ordina SOFTC Presentation - SharePoint - Automated scripted deployment
Ordina SOFTC Presentation - SharePoint - Automated scripted deploymentOrdina SOFTC Presentation - SharePoint - Automated scripted deployment
Ordina SOFTC Presentation - SharePoint - Automated scripted deployment
 
#2 connected apps_calicut_31_july
#2 connected apps_calicut_31_july#2 connected apps_calicut_31_july
#2 connected apps_calicut_31_july
 
Process
ProcessProcess
Process
 
Batch Processing with Mule 4
Batch Processing with Mule 4Batch Processing with Mule 4
Batch Processing with Mule 4
 
Helping agencies to build software business
Helping agencies to build software businessHelping agencies to build software business
Helping agencies to build software business
 
Rollup Summary Trigger for Lookup Relationship Salesforce #Salesforce #ApexTr...
Rollup Summary Trigger for Lookup Relationship Salesforce #Salesforce #ApexTr...Rollup Summary Trigger for Lookup Relationship Salesforce #Salesforce #ApexTr...
Rollup Summary Trigger for Lookup Relationship Salesforce #Salesforce #ApexTr...
 
7-SilverlightFireStarter-Toolkit and Controls - Marco Matos
7-SilverlightFireStarter-Toolkit and Controls - Marco Matos7-SilverlightFireStarter-Toolkit and Controls - Marco Matos
7-SilverlightFireStarter-Toolkit and Controls - Marco Matos
 
Meetup bangalore-may22nd2021
Meetup bangalore-may22nd2021Meetup bangalore-may22nd2021
Meetup bangalore-may22nd2021
 
Pixegon Introduction
Pixegon IntroductionPixegon Introduction
Pixegon Introduction
 
#1 Calicut MuleSoft Meetup - Introduction to Enterprise Integration and MuleSoft
#1 Calicut MuleSoft Meetup - Introduction to Enterprise Integration and MuleSoft#1 Calicut MuleSoft Meetup - Introduction to Enterprise Integration and MuleSoft
#1 Calicut MuleSoft Meetup - Introduction to Enterprise Integration and MuleSoft
 

Similar to ISV Error Handling With Spring '21 Update

Dev ops presentation
Dev ops presentationDev ops presentation
Dev ops presentationAhmed Kamel
 
Retrofitting a legacy SPA to use a functional architecture
Retrofitting a legacy SPA to use a functional architectureRetrofitting a legacy SPA to use a functional architecture
Retrofitting a legacy SPA to use a functional architectureManuel Rivero
 
Building of systems of automatic C/C++ code logging
Building of systems of automatic C/C++ code loggingBuilding of systems of automatic C/C++ code logging
Building of systems of automatic C/C++ code loggingPVS-Studio
 
Code instrumentation
Code instrumentationCode instrumentation
Code instrumentationMennan Tekbir
 
Apex Replay Debugger and Salesforce Platform Events.pptx
Apex Replay Debugger and Salesforce Platform Events.pptxApex Replay Debugger and Salesforce Platform Events.pptx
Apex Replay Debugger and Salesforce Platform Events.pptxmohayyudin7826
 
C programming for Computing Techniques
C programming for Computing TechniquesC programming for Computing Techniques
C programming for Computing TechniquesAppili Vamsi Krishna
 
Spectacular Specs and how to write them!
Spectacular Specs and how to write them!Spectacular Specs and how to write them!
Spectacular Specs and how to write them!YeurDreamin'
 
Refactoring ASP.NET and beyond
Refactoring ASP.NET and beyondRefactoring ASP.NET and beyond
Refactoring ASP.NET and beyondDotNetMarche
 
Error management
Error managementError management
Error managementdaniil3
 
Production Debugging at Code Camp Philly
Production Debugging at Code Camp PhillyProduction Debugging at Code Camp Philly
Production Debugging at Code Camp PhillyBrian Lyttle
 
Workflows via Event driven architecture
Workflows via Event driven architectureWorkflows via Event driven architecture
Workflows via Event driven architectureMilan Patel
 
ERP Magazine April 2018 Issue 1
ERP Magazine April 2018 Issue 1 ERP Magazine April 2018 Issue 1
ERP Magazine April 2018 Issue 1 Rehan Zaidi
 
ERP Magazine April 2018 - The magazine for SAP ABAP Professionals
ERP Magazine April 2018 - The magazine for SAP ABAP ProfessionalsERP Magazine April 2018 - The magazine for SAP ABAP Professionals
ERP Magazine April 2018 - The magazine for SAP ABAP ProfessionalsRehan Zaidi
 
IDE and Toolset For Magento Development
IDE and Toolset For Magento DevelopmentIDE and Toolset For Magento Development
IDE and Toolset For Magento DevelopmentAbid Malik
 
Observability for Application Developers (1)-1.pptx
Observability for Application Developers (1)-1.pptxObservability for Application Developers (1)-1.pptx
Observability for Application Developers (1)-1.pptxOpsTree solutions
 
Computer programing 111 lecture 2
Computer programing 111 lecture 2Computer programing 111 lecture 2
Computer programing 111 lecture 2ITNet
 

Similar to ISV Error Handling With Spring '21 Update (20)

Dev ops presentation
Dev ops presentationDev ops presentation
Dev ops presentation
 
Retrofitting a legacy SPA to use a functional architecture
Retrofitting a legacy SPA to use a functional architectureRetrofitting a legacy SPA to use a functional architecture
Retrofitting a legacy SPA to use a functional architecture
 
Building of systems of automatic C/C++ code logging
Building of systems of automatic C/C++ code loggingBuilding of systems of automatic C/C++ code logging
Building of systems of automatic C/C++ code logging
 
Code instrumentation
Code instrumentationCode instrumentation
Code instrumentation
 
Apex Replay Debugger and Salesforce Platform Events.pptx
Apex Replay Debugger and Salesforce Platform Events.pptxApex Replay Debugger and Salesforce Platform Events.pptx
Apex Replay Debugger and Salesforce Platform Events.pptx
 
C programming for Computing Techniques
C programming for Computing TechniquesC programming for Computing Techniques
C programming for Computing Techniques
 
Spectacular Specs and how to write them!
Spectacular Specs and how to write them!Spectacular Specs and how to write them!
Spectacular Specs and how to write them!
 
Refactoring ASP.NET and beyond
Refactoring ASP.NET and beyondRefactoring ASP.NET and beyond
Refactoring ASP.NET and beyond
 
Spring batch overivew
Spring batch overivewSpring batch overivew
Spring batch overivew
 
Error management
Error managementError management
Error management
 
Production Debugging at Code Camp Philly
Production Debugging at Code Camp PhillyProduction Debugging at Code Camp Philly
Production Debugging at Code Camp Philly
 
Workflows via Event driven architecture
Workflows via Event driven architectureWorkflows via Event driven architecture
Workflows via Event driven architecture
 
Architecture presentation 4
Architecture presentation 4Architecture presentation 4
Architecture presentation 4
 
Making Strongly-typed NETCONF Usable
Making Strongly-typed NETCONF UsableMaking Strongly-typed NETCONF Usable
Making Strongly-typed NETCONF Usable
 
ERP Magazine April 2018 Issue 1
ERP Magazine April 2018 Issue 1 ERP Magazine April 2018 Issue 1
ERP Magazine April 2018 Issue 1
 
ERP Magazine April 2018 - The magazine for SAP ABAP Professionals
ERP Magazine April 2018 - The magazine for SAP ABAP ProfessionalsERP Magazine April 2018 - The magazine for SAP ABAP Professionals
ERP Magazine April 2018 - The magazine for SAP ABAP Professionals
 
IDE and Toolset For Magento Development
IDE and Toolset For Magento DevelopmentIDE and Toolset For Magento Development
IDE and Toolset For Magento Development
 
Observability for Application Developers (1)-1.pptx
Observability for Application Developers (1)-1.pptxObservability for Application Developers (1)-1.pptx
Observability for Application Developers (1)-1.pptx
 
Computer programing 111 lecture 2
Computer programing 111 lecture 2Computer programing 111 lecture 2
Computer programing 111 lecture 2
 
Cp 111 lecture 2
Cp 111 lecture 2Cp 111 lecture 2
Cp 111 lecture 2
 

More from CodeScience

Journey Through the AppExchange: Product-Led Growth with MagicRobot
Journey Through the AppExchange: Product-Led Growth with MagicRobotJourney Through the AppExchange: Product-Led Growth with MagicRobot
Journey Through the AppExchange: Product-Led Growth with MagicRobotCodeScience
 
Journey Through the AppExchange: From SI to ISV with Virsys12
Journey Through the AppExchange: From SI to ISV with Virsys12Journey Through the AppExchange: From SI to ISV with Virsys12
Journey Through the AppExchange: From SI to ISV with Virsys12CodeScience
 
Strategic Partnerships: The New Key to Innovation
Strategic Partnerships: The New Key to InnovationStrategic Partnerships: The New Key to Innovation
Strategic Partnerships: The New Key to InnovationCodeScience
 
Journey Through the AppExchange: How inriver is Filling a Gap for Salesforce ...
Journey Through the AppExchange: How inriver is Filling a Gap for Salesforce ...Journey Through the AppExchange: How inriver is Filling a Gap for Salesforce ...
Journey Through the AppExchange: How inriver is Filling a Gap for Salesforce ...CodeScience
 
Designing Salesforce Platform Events
Designing Salesforce Platform EventsDesigning Salesforce Platform Events
Designing Salesforce Platform EventsCodeScience
 
Ready, Set, Launch: Accelerating Healthcare Innovation One App at a Time
Ready, Set, Launch: Accelerating Healthcare Innovation One App at a TimeReady, Set, Launch: Accelerating Healthcare Innovation One App at a Time
Ready, Set, Launch: Accelerating Healthcare Innovation One App at a TimeCodeScience
 
Journey Through the AppExchange: How Place Technology Created a New Category
Journey Through the AppExchange: How Place Technology Created a New CategoryJourney Through the AppExchange: How Place Technology Created a New Category
Journey Through the AppExchange: How Place Technology Created a New CategoryCodeScience
 
Journey to the AppExchange: How to Launch Into a New Ecosystem
Journey to the AppExchange: How to Launch Into a New EcosystemJourney to the AppExchange: How to Launch Into a New Ecosystem
Journey to the AppExchange: How to Launch Into a New EcosystemCodeScience
 
10 Tips to Pass Salesforce Security Review (and Steps to Take If You Don’t!)
10 Tips to Pass Salesforce Security Review (and Steps to Take If You Don’t!)10 Tips to Pass Salesforce Security Review (and Steps to Take If You Don’t!)
10 Tips to Pass Salesforce Security Review (and Steps to Take If You Don’t!)CodeScience
 
Top 5 Ways to Build Pipeline With AppExchange Chat
Top 5 Ways to Build Pipeline With AppExchange ChatTop 5 Ways to Build Pipeline With AppExchange Chat
Top 5 Ways to Build Pipeline With AppExchange ChatCodeScience
 
Everything You Need to Know About Salesforce LMA & COA
Everything You Need to Know About Salesforce LMA & COAEverything You Need to Know About Salesforce LMA & COA
Everything You Need to Know About Salesforce LMA & COACodeScience
 
Streamline Page Layouts with Dynamic Forms
Streamline Page Layouts with Dynamic FormsStreamline Page Layouts with Dynamic Forms
Streamline Page Layouts with Dynamic FormsCodeScience
 
Getting to Yes: How to build executive alignment to win big on the AppExchange
Getting to Yes: How to build executive alignment to win big on the AppExchangeGetting to Yes: How to build executive alignment to win big on the AppExchange
Getting to Yes: How to build executive alignment to win big on the AppExchangeCodeScience
 
Ready, Set, Deploy: How Place Technology Streamlined Deployment on the AppExc...
Ready, Set, Deploy: How Place Technology Streamlined Deployment on the AppExc...Ready, Set, Deploy: How Place Technology Streamlined Deployment on the AppExc...
Ready, Set, Deploy: How Place Technology Streamlined Deployment on the AppExc...CodeScience
 
How FinancialForce Leverages Labs to Accelerate Innovation
How FinancialForce Leverages Labs to Accelerate InnovationHow FinancialForce Leverages Labs to Accelerate Innovation
How FinancialForce Leverages Labs to Accelerate InnovationCodeScience
 
Acting Like a Top 25 Salesforce ISV: How Appinium Applies Buyer's and Seller'...
Acting Like a Top 25 Salesforce ISV: How Appinium Applies Buyer's and Seller'...Acting Like a Top 25 Salesforce ISV: How Appinium Applies Buyer's and Seller'...
Acting Like a Top 25 Salesforce ISV: How Appinium Applies Buyer's and Seller'...CodeScience
 
Acting Like a Top 25 Salesforce ISV: Designing the Seller's Journey for the ...
Acting Like a Top 25 Salesforce ISV:  Designing the Seller's Journey for the ...Acting Like a Top 25 Salesforce ISV:  Designing the Seller's Journey for the ...
Acting Like a Top 25 Salesforce ISV: Designing the Seller's Journey for the ...CodeScience
 
[Tech Webinar] Second Generation Packaging for ISVs
[Tech Webinar] Second Generation Packaging for ISVs[Tech Webinar] Second Generation Packaging for ISVs
[Tech Webinar] Second Generation Packaging for ISVsCodeScience
 
Webinar: Acting Like a Top 25 Salesforce ISV - Designing Trial Experiences th...
Webinar: Acting Like a Top 25 Salesforce ISV - Designing Trial Experiences th...Webinar: Acting Like a Top 25 Salesforce ISV - Designing Trial Experiences th...
Webinar: Acting Like a Top 25 Salesforce ISV - Designing Trial Experiences th...CodeScience
 
Webinar: Leveraging Context & Dynamics with Lightning Web Component Configura...
Webinar: Leveraging Context & Dynamics with Lightning Web Component Configura...Webinar: Leveraging Context & Dynamics with Lightning Web Component Configura...
Webinar: Leveraging Context & Dynamics with Lightning Web Component Configura...CodeScience
 

More from CodeScience (20)

Journey Through the AppExchange: Product-Led Growth with MagicRobot
Journey Through the AppExchange: Product-Led Growth with MagicRobotJourney Through the AppExchange: Product-Led Growth with MagicRobot
Journey Through the AppExchange: Product-Led Growth with MagicRobot
 
Journey Through the AppExchange: From SI to ISV with Virsys12
Journey Through the AppExchange: From SI to ISV with Virsys12Journey Through the AppExchange: From SI to ISV with Virsys12
Journey Through the AppExchange: From SI to ISV with Virsys12
 
Strategic Partnerships: The New Key to Innovation
Strategic Partnerships: The New Key to InnovationStrategic Partnerships: The New Key to Innovation
Strategic Partnerships: The New Key to Innovation
 
Journey Through the AppExchange: How inriver is Filling a Gap for Salesforce ...
Journey Through the AppExchange: How inriver is Filling a Gap for Salesforce ...Journey Through the AppExchange: How inriver is Filling a Gap for Salesforce ...
Journey Through the AppExchange: How inriver is Filling a Gap for Salesforce ...
 
Designing Salesforce Platform Events
Designing Salesforce Platform EventsDesigning Salesforce Platform Events
Designing Salesforce Platform Events
 
Ready, Set, Launch: Accelerating Healthcare Innovation One App at a Time
Ready, Set, Launch: Accelerating Healthcare Innovation One App at a TimeReady, Set, Launch: Accelerating Healthcare Innovation One App at a Time
Ready, Set, Launch: Accelerating Healthcare Innovation One App at a Time
 
Journey Through the AppExchange: How Place Technology Created a New Category
Journey Through the AppExchange: How Place Technology Created a New CategoryJourney Through the AppExchange: How Place Technology Created a New Category
Journey Through the AppExchange: How Place Technology Created a New Category
 
Journey to the AppExchange: How to Launch Into a New Ecosystem
Journey to the AppExchange: How to Launch Into a New EcosystemJourney to the AppExchange: How to Launch Into a New Ecosystem
Journey to the AppExchange: How to Launch Into a New Ecosystem
 
10 Tips to Pass Salesforce Security Review (and Steps to Take If You Don’t!)
10 Tips to Pass Salesforce Security Review (and Steps to Take If You Don’t!)10 Tips to Pass Salesforce Security Review (and Steps to Take If You Don’t!)
10 Tips to Pass Salesforce Security Review (and Steps to Take If You Don’t!)
 
Top 5 Ways to Build Pipeline With AppExchange Chat
Top 5 Ways to Build Pipeline With AppExchange ChatTop 5 Ways to Build Pipeline With AppExchange Chat
Top 5 Ways to Build Pipeline With AppExchange Chat
 
Everything You Need to Know About Salesforce LMA & COA
Everything You Need to Know About Salesforce LMA & COAEverything You Need to Know About Salesforce LMA & COA
Everything You Need to Know About Salesforce LMA & COA
 
Streamline Page Layouts with Dynamic Forms
Streamline Page Layouts with Dynamic FormsStreamline Page Layouts with Dynamic Forms
Streamline Page Layouts with Dynamic Forms
 
Getting to Yes: How to build executive alignment to win big on the AppExchange
Getting to Yes: How to build executive alignment to win big on the AppExchangeGetting to Yes: How to build executive alignment to win big on the AppExchange
Getting to Yes: How to build executive alignment to win big on the AppExchange
 
Ready, Set, Deploy: How Place Technology Streamlined Deployment on the AppExc...
Ready, Set, Deploy: How Place Technology Streamlined Deployment on the AppExc...Ready, Set, Deploy: How Place Technology Streamlined Deployment on the AppExc...
Ready, Set, Deploy: How Place Technology Streamlined Deployment on the AppExc...
 
How FinancialForce Leverages Labs to Accelerate Innovation
How FinancialForce Leverages Labs to Accelerate InnovationHow FinancialForce Leverages Labs to Accelerate Innovation
How FinancialForce Leverages Labs to Accelerate Innovation
 
Acting Like a Top 25 Salesforce ISV: How Appinium Applies Buyer's and Seller'...
Acting Like a Top 25 Salesforce ISV: How Appinium Applies Buyer's and Seller'...Acting Like a Top 25 Salesforce ISV: How Appinium Applies Buyer's and Seller'...
Acting Like a Top 25 Salesforce ISV: How Appinium Applies Buyer's and Seller'...
 
Acting Like a Top 25 Salesforce ISV: Designing the Seller's Journey for the ...
Acting Like a Top 25 Salesforce ISV:  Designing the Seller's Journey for the ...Acting Like a Top 25 Salesforce ISV:  Designing the Seller's Journey for the ...
Acting Like a Top 25 Salesforce ISV: Designing the Seller's Journey for the ...
 
[Tech Webinar] Second Generation Packaging for ISVs
[Tech Webinar] Second Generation Packaging for ISVs[Tech Webinar] Second Generation Packaging for ISVs
[Tech Webinar] Second Generation Packaging for ISVs
 
Webinar: Acting Like a Top 25 Salesforce ISV - Designing Trial Experiences th...
Webinar: Acting Like a Top 25 Salesforce ISV - Designing Trial Experiences th...Webinar: Acting Like a Top 25 Salesforce ISV - Designing Trial Experiences th...
Webinar: Acting Like a Top 25 Salesforce ISV - Designing Trial Experiences th...
 
Webinar: Leveraging Context & Dynamics with Lightning Web Component Configura...
Webinar: Leveraging Context & Dynamics with Lightning Web Component Configura...Webinar: Leveraging Context & Dynamics with Lightning Web Component Configura...
Webinar: Leveraging Context & Dynamics with Lightning Web Component Configura...
 

Recently uploaded

TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providermohitmore19
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...MyIntelliSource, Inc.
 
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...panagenda
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️Delhi Call girls
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsAlberto González Trastoy
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...harshavardhanraghave
 
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️anilsa9823
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfkalichargn70th171
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdfWave PLM
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Modelsaagamshah0812
 
A Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxA Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxComplianceQuest1
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Steffen Staab
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...ICS
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...Health
 
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female serviceCALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female serviceanilsa9823
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVshikhaohhpro
 
HR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comHR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comFatema Valibhai
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsAndolasoft Inc
 

Recently uploaded (20)

TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
 
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
 
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
 
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
 
Microsoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdfMicrosoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdf
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
 
A Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxA Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docx
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female serviceCALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
 
HR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comHR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.com
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.js
 

ISV Error Handling With Spring '21 Update

  • 1.
  • 2. ● Who is CodeScience? ● Introduction ● Error handling in ISV Applications ● New In Spring ‘21 ● Using these events in packages ● Demo ● Recap Agenda
  • 3. This is an image placeholder for an image. Please size accordingly. ● Founding partner of the Salesforce Product Development Organization (PDO) Program since 2008 - named Master PDO in 2017 ● PDO Program provides app development services to ISVs for the Salesforce AppExchange ● Partner with clients in various industries to assist in building over 300 apps on the AppExchange ● From design to build to implementation, we support through the full lifecycle Who is CodeScience
  • 4. Client success: 10% of the AppExchange
  • 7. Error Handling In ISV Applications
  • 8. Why do errors occur? ● We aren’t perfect, sometimes there are coding mistakes ● Subscribers often misconfigure applications. Missing permissions, credentials, etc. ● Subscribers may build logic, automation, validations, etc that interfere with the normal function of applications ● Subscriber environments may present unanticipated challenges, such as 50M+ accounts, hundreds of Process Builders, inefficient custom code, elaborate sharing models ● Sometimes, errors just happen
  • 9. Reactive Error Handling ● A subscriber notices some functionality is not working, such as “An Unexpected Error Has Occurred”, Apex jobs are in error state, data is not correct, etc. ● They reach out to your customer support with this information, and you have to help diagnose and fix the issue ● This is time-consuming, costly, and can lead to a loss of trust if it happens often
  • 10. Proactive Error Handling ● You attempt to catch errors that you anticipate, and handle them appropriately ● You attempt to catch anything unexpected, with a few options: ○ Store in a “Log” object with visibility to subscriber, and possible trigger logic ○ Emit an event that can be subscribed to ○ “Phone home” with the information (with explicit subscriber consent) ○ Use FMA FeatureParameterInteger to log error counts ○ Flag “problem” records to exclude from processing ○ Implement a retry mechanism
  • 11. New in Spring ‘21
  • 12. New in Spring ‘21 Use BatchApexErrorEvent Triggers to Monitor ISV Applications ● Include BatchApexErrorEvent triggers in your managed package to monitor the health of batch jobs and take necessary corrective action without any post-installation steps ● This change applies to Lightning Experience and Salesforce Classic ● The BatchApexErrorEvent object represents a platform event associated with a failing batch Apex execution
  • 13. BatchApexErrorEvent ● This is a standard Salesforce event, which can be emitted from Batch Apex Classes that encounter errors ● This event can be subscribed to just like normal Platform Events, as well as being able to handle the events with triggers ● It was released in Winter ‘19, but a trigger handler could not be packaged until Spring ‘21 ● It includes information such as job id, error type, record ids being processed, etc. ● It is triggered on any batch error, including “uncatchable” errors, such as limit exceptions
  • 14. Using These Events In Packages
  • 16. What Information do you get? ● What job id was running, from which you can get Apex class & namespace ● The type of exception ● What IDs of the records that were being processed ● The exception message ● The Phase ● The stack trace*** (caveat on next slide)
  • 17. What are the limitations/concerns? ● No stack trace is available when running from a managed package ● This is a standard event, so you get all subscriber and other package events as well ● You should limit your error processing to just Apex classes in your namespace for both data quality & security reasons ● You still don’t get direct access to the error information, and need consent from your customers to send it to you. ● The JobScope (record ids) is limited to 40k characters (~2100 record ids and commas), after which point it will be truncated and DoesExceedJobScopeMaxLength set to true
  • 18. Demo
  • 19. In Summary... ● This new Spring ‘21 feature fills in a gap of batch error handling ● This should be used in conjunction with other available error-handling, such as catching DML errors in the batch and flagging problem records for follow-up ● You could log this information, subscribe to it, phone home, retry the batch, flag problematic records, increase error counts in FMA… ● All of these options should increase the resiliency of your solution, and make debugging issues easier
  • 21. References ● Salesforce Blog Post - https://developer.salesforce.com/blogs/2019/01/building-a-batch-retry -framework-with-batchapexerrorevent.html ● Developer documentation - https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/ape xcode/apex_batch_platformevents.htm ● Technical Documentation - https://developer.salesforce.com/docs/atlas.en-us.platform_events.me ta/platform_events/sforce_api_objects_batchapexerrorevent.htm