Delay in Stripe payment confirmation with Pro Sites

Stripe payment and Pro site are not Synchronized, there is one hour delay for the invoice has the payment confirmed, this will effect every single pro-sites customer if they are paying attention and happen to login to their site during that 1 hour mistake.

Also this function ProSites->is_pro_site() has a query that runs 27 times only when its in the state of flux of this 1 hr gap when things are non-expired it only runs 2x, so that's significant overhead that can occur on a network of blogs that have expired blogs on them...which could be a lot.

  • Adam Czajczyk
    • Support Gorilla

    Hello Ben

    Thank you for your question!

    As for the Stripe/Pro Sites delay. The subscription is set on the gateway side so it's not Pro Sites that "triggers" it but Stripe and Pro Sites only handles the information (that the invoice has been paid) that it receives from Stripe. In Stripe dashboard on "Business settings" page there's a "Timezone" setting - did you make sure that this setting is matching your site's timezone settings (for the main site of the multisite)? I'm asking to make sure that this is consistent first.

    As for the query thing. I have forwarded a question about this to our developers so they could explain and/or fix that and I'm awaiting they response. We'll update you here about it as soon as we got a response from them.

    Kind regards,

  • Ari
    • Recruit

    Hey Ben

    Hope you are fine today!

    This is really an odd issue, seems specific to your site as this is not happening in our test sites.

    Can you give me some information like:

    1: From when you are facing this issue? Can you remember any action?
    2: For further testing I need to do some debugging in the plugin's files, as well I also need to set up my own Stripe credentials, I know this is a live site, and maybe it's not possible, in this case can you please create a staging site with same configurations on same server where this issue also can be replicable?
    3: For debugging purpose, I need your cPanel or FTP details, in your case cPanel is better, cause I may need to check the database too! but FTP is OK initially.
    4: Stripe logs

    === What is Staging Site, and How? ===

    Usually there are 3 options:

    1) You can do that with hosting, if your hosting provide this feature.
    2) You can use tools like Snapshot Managed Backups (or Duplicator premium, All-in-One WP Migration with their pro multisite extension)
    3) You also can do that manually - here is a guidance to do so:

    === How to send the FTP details ===

    You can send them them through our secure contact from:
    Using the below template:

    Subject: "Attn: Ari"
    - WordPress admin (login url/username/password)
    - FTP credentials (host/username/password)
    - cPanel/Plesk credentials (host/username/password)
    - Attach Stripe logs file.
    - link back to this thread for reference (it is:
    - any other relevant urls

    Keep in mind the subject line as ensures that it gets assigned to me.

    Have a great day!
    Warm Regards,

  • Ben
    • The Reaper


    Actually this same issue happens on the wpmudev its not odd at all :smiley:

    Happened on my renewel, i noticed for about an hour or 2 i was told i need to upgrade. I contacted you guys and then after being on hold the auto renewel went through.

    As I told the chat guy, the way your reference your expiration is not properly aligning with how the charge is made. When a subscription is creating, the frame of reference seems to be off.

    Not hard to debug...just look at the time code in the DB of stripe vs pro-site db.

    Also see if how the reference point was calculated changed, say somebody signed up a year ago vs now.

    A huge headache that I solved for you guys is that in previous versions you set up the database flawed, so the db key not being set up right was messing other things up. In the future version you fixed this, but for people that had being using the plugin more than a year...were screwed because the QA for some reason missed it.

    So this being missed..check your frame of reference for the time. Its off.

  • Panos
    • SLS

    Hi there Ben !

    Thanks for your input once more :slight_smile:

    Again this hasn't been reported, but I think it's safe to increase it a few hours or even a day more.

    Could you try adding the following define in your wp-config.php file:
    define('PSTS_EXPIRATION_BUFFER', 172800);
    By default it should be set to 86400, so with the above it gets increased by one more day.

    Please let us know if this helps :slight_smile:


  • Ben
    • The Reaper


    Its hard to spot unless you are looking at the site within the hour...but just do a test on your own wpmudev system. Review an account hat is about to expire and see what happens...its happening your own site....

    That said, thanks for that I will try that out


Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.