#Batching Cloud Code Calls

1 messages · Page 1 of 1 (latest)

fierce imp
#

If you're trying to prevent the duplicate items, you could be enabling/disabling the button while you wait for the request to complete.

Batching is harder. There aren't any guarantees that subsequent calls are going to target the same instance, so in-memory is out of the question.

Are you worried about the number of calls to the database, or managing the concurrency of those operations in a way that errors don't get introduced?

magic edge
#

I'd just rather have a player instance on the server where I can store the amount of bought items in a simple int variable and then write them to the database from there

#

but then I'd need a persistent variable for at least a few seconds that can be accessed from multiple API calls