stanley-king 3 سال پیش
والد
کامیت
2091850363
3فایلهای تغییر یافته به همراه3 افزوده شده و 5 حذف شده
  1. 0 2
      core/framework/db/mysqli.php
  2. 2 2
      helper/refill/util.php
  3. 1 1
      test/TestRefillThird.php

+ 0 - 2
core/framework/db/mysqli.php

@@ -616,7 +616,6 @@ class Db
     public static function commit($host = 'master')
     {
         self::$ifTransacting -= 1;
-
         if (self::$ifTransacting === 0)
         {
             $result = self::$link[$host]->commit();
@@ -634,7 +633,6 @@ class Db
     public static function rollback($host = 'master')
     {
         self::$ifTransacting -= 1;
-
         if (self::$ifTransacting === 0)
         {
             $result = self::$link[$host]->rollback();

+ 2 - 2
helper/refill/util.php

@@ -634,7 +634,7 @@ class util
         }
         $url = BASE_SITE_URL . "/mobile/callback/refill_baidu.php";
         go(function () use ($url, $status,$order_sn) {
-            sleep(30);
+            sleep(1);
             while (true)
             {
                 $resp = http_request($url,['status' => $status,'order_sn' => $order_sn],'GET', false, [], $net_errno);
@@ -658,7 +658,7 @@ class util
 
         $url = BASE_SITE_URL . "/mobile/callback/refill_baidu.php";
         go(function () use ($url, $status,$order_sn) {
-            sleep(30);
+            sleep(1);
             while (true)
             {
                 $resp = http_request($url,['status' => $status,'order_sn' => $order_sn],'GET', false, [], $net_errno);

+ 1 - 1
test/TestRefillThird.php

@@ -122,7 +122,7 @@ class TestRefillThird extends TestCase
         $sender = function ()
         {
             $time = time();
-            for ($i = 0; $i < 100; $i++)
+            for ($i = 0; $i < 1000; $i++)
             {
                 $params = [ 'mchid' => 1092,
                     'buyer_id' => 60221,