Coder Social home page Coder Social logo

cron-fix's Introduction

cron-fix

因为1分钟一次的免费Cron实在太难找,云监控频率又普遍比较低,所以写了这货。它会在前四次执行的时候记录下执行时间,计算出Cron的执行间隔,然后从第五次开始在Cron执行的间隔中依靠自身的循环对Cron进行补充。

简单来说,它会把任意频率的Cron修正到1分钟一次。

测试中使用监控宝15分钟一次和30分钟一次的监控都运行良好,执行时间记录显示执行频率接近标准的1分钟一次。

使用方法是把它改名xcron.php【其它也行啦,别和cron文件重名就好了】,和需要执行的cron.php放在一个目录下,然后把云监控的目标设置为xcron.php。

cron-fix's People

Contributors

puteulanus avatar

Stargazers

Undefined avatar  avatar Kernel Jackson avatar Jimmy66 avatar zzliux avatar 霊烏路  空 avatar tutugreen avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.