• Resolved nwr91

    (@nwr91)


    Had an email from our hosting provider that they are at the point of having to suspend 2 sites that use the Salesforce Sync plugin.

    They say they are consistently running 100’s of DELETE SQL queries of the same action_id, and a long-running query that takes 3+ hours to complete.

    The issues are listed below.

    DELETE FROMwp_actionscheduler_actionsWHEREaction_id= 1353679

    SELECT SQL_CALC_FOUND_ROWS  wp_posts.ID FROM wp_posts  LEFT JOIN wp_postmeta ON ( wp_posts.ID = wp_postmeta.post_id )  LEFT JOIN wp_postmeta AS mt1 ON ( wp_posts.ID = mt1.post_id AND mt1.meta_key = 'associated_review' ) WHERE 1=1  AND (
      ( wp_postmeta.meta_key = 'associated_review' AND wp_postmeta.meta_value = '' )
      OR
      mt1.post_id IS NULL
    ) AND wp_posts.post_type = 'film' AND ((wp_posts.post_status = 'publish')) GROUP BY wp_posts.ID ORDER BY wp_posts.post_date DESC LIMIT 0, 200

    Both sites are fully up-to-date with WP and plugins. Please resolve urgently.

    • This topic was modified 3 years, 1 month ago by nwr91.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Jonathan Stegall

    (@jonathanstegall)

    Well, I can tell you that the DELETE FROM SQL statement is related to the ActionScheduler library, which this plugin does include. It’s also included with Woocommerce (they develop it) and many other plugins.

    But in general, if it’s an urgent issue, you may need to set up a staging site, disable all other plugins and themes, turn on debug logging, etc. and see if it’s still happening.

    If it does turn out to be an urgent issue, I would greatly welcome pull requests that could fix it for anyone else who might encounter it. But to be clear, unless you can specify that it is caused by this plugin and how exactly it can be reproduced I’m not sure that it’s something I can resolve for you.

    Thread Starter nwr91

    (@nwr91)

    We have already narrowed it down to the Salesforce Sync plugin. The site is not using any other plugin that uses the ActionScheduler library.

    The long-running SELECT is probably unrelated, but that still doesn’t explain the multi-100 DELETE FROM statements.

    Plugin Author Jonathan Stegall

    (@jonathanstegall)

    Okay, to give some more detail then: I realize the query is related to this plugin. But there’s clearly a reason your site is not deleting actions that Action Scheduler runs in smaller quantities on its own, as that library generally does, and I can’t speak to what that reason is. It might be caused by this plugin, it might be caused by a conflict with another plugin or theme, it might be caused by limitations your host has, it might be caused specifically by your fieldmap configurations – by fields or objects you’re trying to work with that don’t work well – or by issues with your Salesforce, by Action Scheduler itself, or by some combination of those things. In any case, there isn’t enough information for me to know whether there is an issue with this plugin specifically, much less to resolve it, without knowing how to reproduce it.

    Figuring that out may be something that you need to hire out, if you don’t have the capacity, and again, I would welcome pull requests or knowledge of how to reproduce it if it does become clear that there’s an issue with this plugin. I’m sure the Action Scheduler people would as well, if there’s an issue with their library.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘SQL Issues’ is closed to new replies.