1

Are there any best practices relating to the use of the Rest API within an environment with large data volumes?

I am aware of the SOQL best practices relating to LDV. Does this relate at all to individual calls through rest API?

I am debugging an issue for a client around LDV where the Rest API is in use, but do not have access to any debug information or the actual custom build process that is reporting the issues. They are reporting time-outs from the external system.

PATCH and GET methods are in use:

/services/data/v20.0/sobjects/Account/Customer_ID__c/9999999

  • Seperate from the answer - How many fields are you trying to retrieve also? For LDV You may want to consider using a Skinny Table. Above REST call will return all fields I believe, which will impact the performance. – CoryCowgill Nov 25 '14 at 21:37
  • Also - V20.0 is ancient. Have you tried updated to v32.0? V20 is over 3 years old........... – CoryCowgill Nov 25 '14 at 21:38
  • Thanks... yes agree v20 is a bit out, this has been, highlighted.. unfortunately the upgrading is out of my hands. – dacology Nov 25 '14 at 23:04
  • Yes, return all fields. The issues are around the patch/upsert, which is updating around 10 fields. – dacology Nov 25 '14 at 23:05
  • Do ANY API calls work on the client? Or is it just LDV objects? Did they change a firewall setting or block traffic to SFDC to rule out some infrastructure item on client side? If you're confident it is only LDV API calls then you could look at the Workflows, Triggers, etc. on SFDC tier to identify it custom logic is running long. – CoryCowgill Nov 26 '14 at 15:44
1

Yes, to my knowledge the LDV Best Practices apply to your API calls as well as SOQL.

Behind the scenes at the Physical Data Layer (Oracle) that lives underneath the Metadata Kernel the SQL that is constructed is the same regardless of invocation point (SOQL or API Rest) ---- I believe.

This whitepaper is pretty good on explaining some of the underlying mechanisms of Force.com which can explain LDV best practices, etc.

https://developer.salesforce.com/page/Multi_Tenant_Architecture

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.