开发者

Salesforce API 10 request limit

I read somewhere that the Salesforce API has a 10 request limit. If we write code to integrate with Salesforce: 1. What is the risk of this limit 2. How can we write code to negate this开发者_如何转开发 risk?

My real concern is that I don't want to build our customer this great standalone website that integrates with Salesforce only to have user 11 and 12 kicked out to wait until requests 1-10 are complete?

Edit: Some more details on the specifics of the limitation can be found at http://www.salesforce.com/us/developer/docs/api/Content/implementation_considerations.htm. Look at the section titled limits.

"Limits There is a limit on the number of queries that a user can execute concurrently. A user can have up to 10 query cursors open at a time. If 10 QueryLocator cursors are open when a client application, logged in as the same user, attempts to open a new one, then the oldest of the 10 cursors is released. This results in an error in the client application. Multiple client applications can log in using the same username argument. However, this increases your risk of getting errors due to query limits. If multiple client applications are logged in using the same user, they all share the same session. If one of the client applications calls logout(), it invalidates the session for all the client applications. Using a different user for each client application makes it easier to avoid these limits.*"


Not sure which limit you're referring to, but the governor limits are all listed in the Apex documentation. These limits apply to code running in a given Apex transaction (i.e. in response to a trigger/web service call etc), so adding more users won't hurt you - each transaction gets its own allocation of resources.

There are also limits on the number of long-running concurrent API requests and total API calls in a day. Most of these are per-license, so, again, as the number of users rises, so do the limits.


Few comments on:

I don't want to build our customer this great standalone website that integrates with Salesforce only to have user 11 and 12 kicked out to wait until requests 1-10 are complete?

There are two major things you need to consider when planning real-time Sfdc integration beside the api call limits mentioned in the metadaddy's answer (and if you make a lot of queries it's easy to hit these limits):

  1. Sfdc has routine maintainance outage periods.
  2. Querying Sfdc will always be significantly slower than a querying local datasource.

You may want to consider a local mirror of you Sfdc data where you replicate your Sfdc data.

Cheers, Tymek


  • All API usage limits are calculated over 24 hours period
  • Limits are applicable to whole organization. So if you have several users connecting through API all of them count against the same limit.
  • You get 1,000 API requests per each Salesforce user. Even Unlimited Editions is actually limited to 5,000.
  • If you want to check your current API usage status go to Your Name | Setup | Company Profile | Company Information
  • You can purchase additional API calls

You can read more at Salesforce API Limits documentation

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜