function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Dynamic D 6Dynamic D 6 

Custom Web service error handling.

While designing custom web service, which are the errors we should consider while developing.
exp :Too many soql, Heap size limit, connection time out ect.
Please copy paste sample or important links.

Thanks in advance.

 
Amit Chaudhary 8Amit Chaudhary 8
Hi Dynamic D 6,

If you are using any SOQL query then please add limit in that query.
for exmple

List<Account> lstAccount = [select id, name from account limit 1000 ];

Understanding Execution Governors and Limits
https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_gov_limits.htm

IMP link for you
https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/langCon_apex_SOQL_VLSQ.htm

Please mark this as solution by selecting it as best answer if this solves your problem, So that if anyone has this issue this post can help

Thanks
Amit Chaudhary
amit.salesforce21@gmail.com
Dynamic D 6Dynamic D 6
@Amit Chaudhary 8 : I am not looking for governor limit or how to write SOQL ect.
but curious to know how you will write ideal web service which can hundle exception.
 
Amit Chaudhary 8Amit Chaudhary 8
I hope below link will help you :-

1) Please download "Integration Patterns and Practices - Salesforce.com" Book
https://resources.docs.salesforce.com/sfdc/pdf/integration_patterns_and_practices.pdf

2)Apex Web Services and Callouts
https://developer.salesforce.com/page/Apex_Web_Services_and_Callouts

3)
http://www.salesforce.com/us/developer/docs/api/index.htm

Please let us know if this will help you