Private Optional cancelPrivate Readonly connectionPrivate Readonly deployedPrivate Readonly errorsPrivate isPrivate Readonly loggerPrivate Readonly lookupReadonly optionsPrivate Readonly orgPrivate Readonly recordPrivate Readonly recordPrivate Readonly recordsPrivate Readonly salesforcePrivate Readonly schemaPrivate timerGets the total number of datapacks in this deployment. Each datapack can contain multiple records. Use totalRecordCount to get the total number of records.
The total number of datapacks.
Gets the total record count in this deployment. Each record is a part of a datapack.
The total number of records.
Rest ...records: DatapackDeploymentRecord[]Add a Datapack level error to the deployment. This is used to add errors that are not related to a specific record but to a whole datapack, or to add errors that are related to a datapack for which the records could not added to the deployment.
Group key of the datapack to which the error belongs
Error to add to the deployment
Private createCompared the to be deployed records to the records in the org
Records to deploy
Optional cancelToken: CancellationTokenCancellation token to signal the process if a cancellation is initiated
Returns an array of keys from the datapacks in this deployment. The keys returned by this method can be used to retrieve deployment records using getRecords.
An array containing all datapack keys.
Private deployOptional cancelToken: CancellationTokenEmit an event and await the event completion
event type that is emptied
parameters matching the event type
Optional options: EventEmitOptionsPrivate formatGets the deployment status of a Datapack by it's source key.
undefined if the datapack is not part of the deployment.Datapack key to get the deployment status for
Retrieves all datapack deployment records as DatapackDeploymentRecordGroup objects. The return groups can be manipulated when the deployment hasn't started yet.
An array of DatapackDeploymentRecordGroup objects.
Private getGet all records that can be deployed; i.e records that do not have any pending dependencies.
Retrieves the deployment messages for the datapack deployment.
Optional options: { An optional object that specifies additional options for retrieving the messages.
Optional includeA boolean indicating whether to include cascade failures in the messages. Default is false.
An array of DatapackDeploymentRecordMessage objects representing the deployment messages.
Optional options: { Optional includeGets the deployment status of a record by source key
Record source key to get the deployment status for
Private getCompared the to be deployed records to the records in the org
Records
Optional cancelToken: CancellationTokenCancellation token to signal the process if a cancellation is initiated
Get all records related a specific datapack, includes main record and any child records originating from the same datapack.
Key of the datapack
Retrieves all datapack deployment records as DatapackDeploymentRecordGroup objects. The return groups can be manipulated when the deployment hasn't started yet.
An array of DatapackDeploymentRecordGroup objects.
Private handlePrivate handlePrivate hasPrivate hasCheck if a record has pending dependencies that are not yet deployed as part of the current deployment
Private isChecks if there is a circular dependency between two datapacks.
The key of the first datapack.
The key of the second datapack.
True if there is a circular dependency, false otherwise.
Private isRegister an event listener to trigger on an event.
Listener to register
Protected onRegister an event listener to trigger once on event.
Listener to register
Private purgePrivate purgePurge all records that depend on any of the records just deployed through their matching record key. Records that depend on other records from within the same Datapack have a relation to the parent datapack through Matching source key. This function will delete all child records that have a relationship parent record through a Matching source key
Note this function will only delete records for parents that have been update and are deployed successfully
Records
Removes all listeners, or those of the specified event.
It is bad practice to remove listeners added elsewhere in the code, particularly when the EventEmitter instance was created by some other component or module (e.g. sockets or file streams).
Returns a reference to the EventEmitter, so that calls can be chained.
Optional event: Kevent type to remove listeners for if not specified all listeners are removed
Removes the specified listener from the listener array for the event named event.
removeListener() will remove, at most, one instance of a listener from the listener array.
If any single listener has been added multiple times to the listener array for the specified eventName,
then removeListener() must be called multiple times to remove each instance.
event type to remove listener from
listener to remove
Private reportPrivate resolveOptional cancelToken: CancellationTokenResolve a dependency either based on the records we are deploying -or- pass it on to the lookup resolver.
Dependency
Private resolvePrivate resolveOptional cancelToken: CancellationTokenDeploy deployment records part of this deployment task to Salesforce.
Optional cancelToken: CancellationTokenAn optional cancellation token to stop the deployment
Private validatePrivate write
A datapack deployment task/job