HomeGuidesDeveloper HubRelease Notes
Get supportBook a chat
Guides
These docs are for v2.114. Click to read the latest docs for v2.208.

Points Expiration Custom Parameters

To aid in high-volume implementations, there are some parameters that you as an admin can configure in order for the Partial Expiration batch job to remain within Salesforce governor limits when the number of Point records in the database grows very large.

Add Available Parameters

These parameters don't come out of the box with the FieloPLT package. You as an admin need to create them in the Custom Setting called FieloPLT.PublicSettings__c so that the Partial Expiration batch job can make use of them.

The parameters are custom fields that you can add to the FieloPLT.PublicSettings__c custom setting. To include them, go to Setup > Custom Settings, navigate to Public Settings in the FieloPLT namespace, and add the custom fields listed below. Be sure that the API names, field types and default values match what is listed below.

Parameters

ParameterTypeDefaultDescription
PointExpirationMaxAttempts__cNumber10Number of times the batch will automatically be re-executed to expire points when the batch fails.
PointExpirationMaxChain__cNumber20Number of times the batch will automatically be re-executed to expire all points.
PointExpirationQueryLimit__cNumber45000Number of Member records to get from the database to expire their point records
PointExpirationDMLLimit__cNumber2500Number of points the batch can expire on each chunk. If not all points are expired, the batch will try again according to the PointExpirationMaxChain__c parameter
PointExpirationBatchSize__cNumber200Batch size of the batch execution. It means it will go expiring the points in chunks of 200 (default) members. It can lead to many point records to be expired (more than 200, because it will be like 200 * [Point Records] (Point Records = Number of point records the member has)
PointExpirationFromDate__cDatenullFrom Date to be used as the first date of the point records to expire
PointExpirationMaxRange__cNumber200Number of days to get from the database starting from the PointExpirationFromDate__c parameter

Example

If you only set the parameter PointExpirationFromDate__c to, for example, 08/15/2022:

  • The batch will try to expire the 2500 (PointExpirationDMLLimit__c) points from the members that are found in the first 45000 point (PointExpirationQueryLimit__c) records from 08/15/2022 to 03/03/2023 (FromDate + 200) (PointExpirationMaxRange__c). But if that leads to updating more than 2500 rows (PointExpirationDMLLimit__c) the batch will continue expiring those points in the next execution.
  • If one or more chunks fail, the batch will try again 10 times (PointExpirationMaxAttempts__c)
  • In order to expire all points on that given period, the batch will be automatically executed 20 times (PointExpirationMaxChain__c)
  • The chunks try to expire up to 2500 point records (PointExpirationDMLLimit__c) from of 200 members (PointExpirationBatchSize__c)

Did this page help you?