How often to update the data in the background?

Hi master.
Please tell me how you would do in a situation like mine.
I have a game, in this game the user earns different things that he can immediately after production, selling, receiving virtual currency, or may destroy it, having the opportunity to grab a bonus. And sometimes they do nothing, and things just hang in the indeterminate status. Because it was made after hours, update the status of this item sold, and to accrue in-game currency. Please tell me how to do this?
The first thing that came to mind is to write a script that will be executed reversed, it will retrieve from the database the records with a certain status and time, and update all information.
I was wondering, crowns, heavily loading the server? And if I run every minute run script, is this normal? Or how often do you think it is advisable to run?

I would be very grateful for the tips;)
August 19th 19 at 22:44
2 answers
August 19th 19 at 22:46
As elsewhere, there are several ways, for example:
* Crowns every 10 minutes, it will not be a big burden and I don't think game mechanics are broken if the item is not sold in an hour, and an hour and 5 minutes.
* Do not do crowns, and when the next request list of things to check for the presence of "old" stuff and automatically change the money. Then the load will be more selective, "smeared" in time, + you will still have the request to the clothes, then it to process, save a lot of queries and resources.
August 19th 19 at 22:48
Cron normally. He did not ship, it all depends on the startup script.

Find more questions by tags MySQLPHP