开发者

Authorization hangs due to rest api call

I've logged a post here: http://facebooksdk.codeplex.com/Thread/View.aspx?ThreadId=241790 which will give you the detail, but I'm having a problem using the SDK due to a call using the rest api rather than the graph api.

Is there a configuration setting somewhere where I can force all requests to go via the Graph api or as the call in question is开发者_StackOverflow中文版 buried within the SDK itself, will I have to write the code to perform this request myself?

Any help would be greatly appreciated

Rich


There isn't actually a graph method with the same functionality as the REST call yet. That is why we are using the REST API.

The implementation however, as you have noticed is not ideal. The issue is that you should actually not be making any api request to check permissions. You will notice that the method you are referring to is virtual. The 'correct' way to use the CanvasAuthorize attribute is actually to implement your own and override the GetPermissions method. You would override the method to check for permissions that the user has from a database or something rather than making a API request. You load the permissions into the database by using the real-time api and subscribing to the permission change event. You can read more about that here: http://developers.facebook.com/docs/api/realtime

This isn't a super easy thing to do, but it is the way you will get the performance you desire.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜