I observed the database at the specified time and found that the specified data had not changed, that is, the planned task was not executed. I heard that it was executed only after opening the page, and I was convinced. Why doesn't this team use event scheduling?
I observed the database at the specified time and found that the specified data had not changed, that is, the planned task was not executed. I heard that it was executed only after opening the page, and I was convinced. Why doesn't this team use event scheduling?
You have two questions:
Discuz did not execute the scheduled task
Discuz’s development team does not use event scheduling
First question, it should be said that if your website does not have any user access, it may not be executed. After all, Discuz’s scheduled tasks are triggered. As for how to solve it, it is recommended to look for posts like this. It may be caused by upgrading or installing plug-ins.
The second question should be determined by the design idea of Discuz. I guess its design idea is to use the most basic php and mysql to complete the main functions, so event scheduling was not considered during the design.
Because he has to consider the space used by the user
Virtual hosts do not have crontab permissions, and technology has always been weighed under restrictions.
I think this function may be:
Write the configuration to a randomly named file, and then PHP ignores the user's shutdown, and the infinite loop runs until the point is executed. If it is found that the configuration file does not exist, it will exit.