Skip to content

0.6.0: optimize integration query strategy #67

@lkraav

Description

@lkraav

I noticed https://github.com/gedex/wp-slack/blob/master/includes/event-manager.php#L58 already has a note about caching.

Currently this plugin prepares all integrations for delivery, always, on every request, even when there's no chance of any of the configured delivery events of being fired.

Better strategy:

  • on integration post_save action, index target event actions, like woocommerce_order_status_completed, as a serialized array in an options table, autoload = true
  • on every request, get_option and set up a "boot integration routine" on indexed actions only (priority 0)
  • in boot action callback, get_posts() only relevant integrations to this action, and attach callbacks

Your thoughts?

PS I also notice the plugin development has stalled for a long time. Burnout?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions