Why do I get the error "Invalid record hashcode from bulk job"?
Question
When attempting to copy all Contact records, errors occur stating "Invalid record hashcode. Unable to find matching record from the response returned by the bulk job."
The export.json
configuration is:
{
"operation": "Upsert",
"externalId": "Email",
"query": "SELECT Id, Name, Email, Platform_Role__c, LastName, FirstName, Salutation, Secondary_Email__c, MailingCity FROM Contact"
}
Console output indicates:
[WARN][Batch#7502g000000rYc5AAE:Insert] {Contact} Incompleted.
51901 records succeeded, 592 records failed.
Despite the warning, no Contact records were successfully inserted into the target.
Answer
By default, the plugin utilizes Bulk API V2.0.
Errors like these can occur with this API, and there is no permanent solution available.
As a workaround, switch to Bulk API V1.0 by setting bulkApiVersion: "1.0"
in your configuration. This change often resolves such issues:
{
"objects": [
{
"operation": "Upsert",
"externalId": "Email",
"query": "SELECT Id, Name, Email, Platform_Role__c, LastName, FirstName, Salutation, Secondary_Email__c, MailingCity FROM Contact"
}
],
"bulkApiVersion": "1.0"
}