7

It's new and it's sad. Since last Friday, it appears that Google have decided to limit the numbers of queries to the Leaderboard via loadCurrentPlayerLeaderboardScore.

I have a game that requests the access to 4 Leaderboards simultaneously, and since Friday, that's what I am receiving:

11-30 10:12:51.557 12993-12993/? I/LEADERBOARD: Request n0 : STATUS_OK
11-30 10:12:51.597 12993-12993/? I/LEADERBOARD: Request n1 : STATUS_OK
11-30 10:12:51.767 12993-12993/? I/LEADERBOARD: Request n2 : STATUS_OK
11-30 10:12:51.898 12993-12993/? I/LEADERBOARD: Request n3 : STATUS_NETWORK_ERROR_NO_DATA

If I invert the requests order:

11-30 10:30:31.431 12993-12993/? I/LEADERBOARD: Request n2 : STATUS_OK
11-30 10:30:31.642 12993-12993/? I/LEADERBOARD: Request n3 : STATUS_OK
11-30 10:30:31.832 12993-12993/? I/LEADERBOARD: Request n0 : STATUS_OK
11-30 10:30:31.952 12993-12993/? I/LEADERBOARD: Request n1 : STATUS_NETWORK_ERROR_NO_DATA

And finally, if I double the requests:

11-30 10:38:53.521 12993-12993/? I/LEADERBOARD: Request n0 : STATUS_OK
11-30 10:38:53.691 12993-12993/? I/LEADERBOARD: Request n1 : STATUS_OK
11-30 10:38:53.892 12993-12993/? I/LEADERBOARD: Request n2 : STATUS_OK
11-30 10:38:54.022 12993-12993/? I/LEADERBOARD: Request n3 : STATUS_NETWORK_ERROR_NO_DATA
11-30 10:38:55.944 12993-12993/? I/LEADERBOARD: Request n0 : STATUS_NETWORK_ERROR_NO_DATA
11-30 10:38:55.994 12993-12993/? I/LEADERBOARD: Request n1 : STATUS_NETWORK_ERROR_NO_DATA
11-30 10:38:56.084 12993-12993/? I/LEADERBOARD: Request n2 : STATUS_NETWORK_ERROR_NO_DATA
11-30 10:38:56.234 12993-12993/? I/LEADERBOARD: Request n3 : STATUS_NETWORK_ERROR_NO_DATA

Like you can see, only 3 requests are now authorized by Google. The official documentation mentions nothing about that. Any idea how to circumvent this?

Edit : After a couple of tests, I discovered that the limit is about of 3 requests max per +-20 sec.

Greelings
  • 4,964
  • 7
  • 34
  • 70
  • 1
    Most of Google's other APIs have a limit on the number of requests you can make per second. 3 per 20s sounds really low though. Maybe you can try spreading out your requests instead of making them all at one time. – Andy Dec 01 '15 at 20:36
  • Thank you @Andy. The interesting thing is that it was working before. I tried to spread the requests with 10sec between each, it gave me the same result! :o With 15sec between each, the first time everything went fine, but the second time, only the first request worked. I really do not understand. :( – Greelings Dec 02 '15 at 09:17
  • 3
    Any news about it? I'm also having the same issue! – thiagolr Dec 27 '15 at 14:00
  • @thiagolr, unfortunately, no. I resigned myself to use only one query at a time. The result : my users have lost some content, and me the opportunity to cross the data. :( – Greelings Dec 28 '15 at 14:36
  • @Denis How did you solved this problem? I'm facing the same issue. http://stackoverflow.com/questions/41468791/unable-to-retrive-google-play-game-services-leaderboard-score?noredirect=1#comment70146920_41468791 – akshay bhange Jan 04 '17 at 18:31
  • @akshaybhange Unfortunately no :( – Greelings Jan 05 '17 at 21:45
  • 1
    @Denis I've found a way.. I'm keeping delay of 45 seconds after 2 leaderboard fetch and I'm keeping this whole code in AsyncTask so that even after activity destroy this code will run and will not affect UI.. – akshay bhange Jan 06 '17 at 04:52

0 Answers0