File tree Expand file tree Collapse file tree 2 files changed +16
-2
lines changed
app/code/Magento/Sales/Model/ResourceModel/Provider
dev/tests/integration/testsuite/Magento/Sales/Model/ResourceModel Expand file tree Collapse file tree 2 files changed +16
-2
lines changed Original file line number Diff line number Diff line change 6
6
namespace Magento \Sales \Model \ResourceModel \Provider ;
7
7
8
8
use Magento \Framework \App \ResourceConnection ;
9
+ use Magento \Framework \DB \Adapter \AdapterInterface ;
9
10
10
11
/**
11
12
* Provides latest updated entities ids list
@@ -17,6 +18,11 @@ class UpdatedIdListProvider implements IdListProviderInterface
17
18
*/
18
19
private $ resourceConnection ;
19
20
21
+ /**
22
+ * @var AdapterInterface
23
+ */
24
+ private $ connection ;
25
+
20
26
/**
21
27
* IdListProvider constructor.
22
28
* @param ResourceConnection $resourceConnection
@@ -58,10 +64,16 @@ private function getLastUpdatedAtValue($gridTableName)
58
64
}
59
65
60
66
/**
61
- * @return \Magento\Framework\DB\Adapter\AdapterInterface
67
+ * Returns connection.
68
+ *
69
+ * @return AdapterInterface
62
70
*/
63
71
private function getConnection ()
64
72
{
65
- return $ this ->resourceConnection ->getConnection ();
73
+ if (!$ this ->connection ) {
74
+ $ this ->connection = $ this ->resourceConnection ->getConnection ('sales ' );
75
+ }
76
+
77
+ return $ this ->connection ;
66
78
}
67
79
}
Original file line number Diff line number Diff line change @@ -32,6 +32,8 @@ protected function setUp()
32
32
/**
33
33
* Tests asynchronous insertion of the new entity into order grid.
34
34
*
35
+ * @magentoDbIsolation enabled
36
+ * @magentoAppIsolation enabled
35
37
* @magentoDataFixture Magento/Sales/_files/order_async.php
36
38
*/
37
39
public function testRefreshByScheduleAsyncModeSuccess ()
You can’t perform that action at this time.
0 commit comments