Code Monkey home page Code Monkey logo

action-scheduler-high-volume's Introduction

Note: With the major improvements added to Action Scheduler 3.0, most notably the migration to custom tables for storing actions and loopback requests to chain the processing of actions, the tweaks available in this plugin should be required far less often than with earlier versions of Action Scheduler.

The code here remains mostly to demonstrate how to tweak some of the configuration that influences throughput.

Action Scheduler High Volume

Increase the processing thresholds for Action Scheduler to process large queues of actions more quickly. Handy for high volume websites with more server resources.

This plugin will change the Action Scheduler:

  • Time Limit: to process queues for up to 120 seconds, instead of the default limit of 30 seconds*.
  • Batch Size: to process batches of 100 actions and reduce time taken to claim additional actions.
  • Concurrency: to allow 10 concurrent queues to process actions, up from 5.
  • Runner Initialization Rate: to start 5 queues every time WP Cron triggers Action Scheduler (scheduled to be every minute) instead of one queue.

For more details on these changes, refer to the Action Scheduler Performance Tuning guide.

* WP Engine only supports a maximum of 60 seconds per request - if using WP Engine, the time limit set by this plugin in the ashp_increase_time_limit() function will need to be decreased from 120 to 60.

action-scheduler-high-volume's People

Contributors

lcmry avatar thenbrent avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

action-scheduler-high-volume's Issues

PHP Fatal error line 43

Hello,

i got this error on line 43. There is something wrong.

PHP Fatal error: Uncaught Error: Call to undefined function add_filter() in /var/www/vhosts/kaufbeet.de/httpdocs/action-scheduler-high-volume.php:43
Stack trace:
#0 {main}
thrown in /var/www/vhosts/kaufbeet.de/httpdocs/action-scheduler-high-volume.php on line 43

composer.json file?

Would you all be interested in adding a composer.json file for those of us who use it to manage dependencies? If so, I'd be happy to submit a PR, but someone would need to publish on packagist.

Since enabling ASHV, `woocommerce_payment_complete` processing chain fails to execute an otherwise normally working filter

Traceback https://sentry.io/share/issue/beaf5527005d44719cbe5664ecc16414/

If you could peek at "plugins/woocommerce-freshbooks/includes/class-wc-freshbooks-handler.php in auto_create_invoice at line 148" there's a custom apply_filters( 'wc_freshbooks_auto_create_invoices', true, $order ) call for a platform plugin to determine whether this invoice should be auto-created.

Since enabling ASHV, renewal payments are failing to trigger this filter. New transactions work fine. It's like during ASHV processing, our platform plugin is not getting loaded at all, which is otherwise initialized via add_action( 'plugins_loaded', 'cxli', 11 ); singleton instantiation call, and I was thinking whether ASHV could somehow be short-circuiting things for performance.

Any thoughts here? I think I will go look for a constant of some kind to identify an AS queue run, and inject another traceback trigger to see what the platform plugin loading state is during ASHV execution. Better ideas would be much appreciated ๐Ÿ‘

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.