We’ve built an app using Facebook PHP SDK. Quite often (too often to count it negligible) requests result in exception (obviously timeout). What is the best way to deal with this? Are there any options we could tweak to decrease the frequency at least?
Share
I’m searching information about this topic too.
A couple of things to keep in mind:
1) your server, if your hosting plan is cheap (let’s face it), it will probably fail with a considerable amount of requests.
2) Optimize your api calls and if it’s possible, change it for FQL queries. This happened to me yesterday, my app needed to extract the name (via php sdk api call) of four friends selected by the user. For each friend I was asking facebook for the complete profile [$this->api(‘ID’)].
You might think “well, at the end the profile is just 4 or 5 data fields”. I really don’t know the impact of this query, but I was getting a lot of timeouts. Then I changed the query for a FQL query (using the SDK, but only selecting the name field). The timeouts are gone.
As I said, I’m still looking for information about optimizing api calls, but I hope you can start with this.
Regards.