Enable Salesforce Files
To enable Salesforce Files, you must configure two settings. The first setting is to include the actual objects that store the Content File information on Salesforce either with pulsar.sync.objects or with pulsar.sync.relationship.directives. The second setting (pulsar.sync.cdl.objects) allows you to specify which parent objects Pulsar should sync Files for.
Modify one of the following two settings depending on your setup.
Key | pulsar.sync.objects |
---|---|
Value | ... ContentDocument ContentDocumentLink ContentVersion ... |
If you are using relationship sync directives instead, add these objects only at depth 0:
Key | pulsar.sync.relationship.directives |
Value | ... |
Also specify this setting to sync files attached to specific objects.
Key | pulsar.sync.cdl.objects |
---|---|
Value | <object type list separated by commas or newlines> |
For example, to sync Files for Contacts and Accounts specify this value:
Account
Contact
When using relationship directives in combination with this setting, a ContentDocumentLink directive will be automatically added (behind the scenes) for every directive where the target object type is one of the types in this cdl.objects setting (at the next higher depth). Also, subsequent sync stages will retrieve the ContentDocument and ContentVersion objects that are specifically referenced by the downloaded ContentDocumentLink objects.
Specifying these two settings will sync the content records that the user can access, but will not automatically retrieve the actual file during sync. Depending on your requirements, you may prefer to have your users not pre-download all the files, but to download individual files on demand (network connectivity permitting). If, however, you require your users to always have access to the files, specify the base64 setting below.
Include or modify the Base64 download sync setting to include ContentVersion:
Key | pulsar.sync.base64download.enabledObjects |
---|---|
Value | ContentVersion |
Admins will need to add the Files related list to the page layouts in order to see Files within Pulsar.
API Limitations
While Salesforce generally allows Pulsar to query for server deleted records in order to remove them from the local device, they do not provide this feature for all objects. The objects associated with content files (ContentDocument, ContentDocumentLink, and ContentVersion) are among those that do not have this support. This means that Pulsar is currently unable to determine when files get deleted from the server via a typical sync. The current work around to this is to run a special type of sync (single object sync) from the parent object. This limited sync can query for all content document link records associated with that single parent object and automatically removes any local records that were not found.Â
Salesforce Files related list support is also not available within Pulsar for Event and Task objects.Â
Estimate Additional API Calls
Also, note that enabling Salesforce Files sync may result in an increase of API calls during the catch-up syncs compared to other stages of sync depending on how many Files the user has access to. To estimate how many additional calls are made with each sync, take the number of files the user has access to and divide by 100.