Skip to content

Commit 889824e

Browse files
committed
Increased allowed query complexity to 300
1 parent 4328497 commit 889824e

File tree

2 files changed

+62
-3
lines changed

2 files changed

+62
-3
lines changed

app/code/Magento/GraphQl/etc/di.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@
100100
<type name="Magento\Framework\GraphQl\Query\QueryComplexityLimiter">
101101
<arguments>
102102
<argument name="queryDepth" xsi:type="number">20</argument>
103-
<argument name="queryComplexity" xsi:type="number">250</argument>
103+
<argument name="queryComplexity" xsi:type="number">300</argument>
104104
</arguments>
105105
</type>
106106
</config>

dev/tests/api-functional/testsuite/Magento/GraphQl/Framework/QueryComplexityLimiterTest.php

Lines changed: 61 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,66 @@ public function testQueryComplexityIsLimited()
263263
percentage_value
264264
website_id
265265
}
266+
tier_prices {
267+
customer_group_id
268+
qty
269+
percentage_value
270+
website_id
271+
}
272+
tier_prices {
273+
customer_group_id
274+
qty
275+
percentage_value
276+
website_id
277+
}
278+
tier_prices {
279+
customer_group_id
280+
qty
281+
percentage_value
282+
website_id
283+
}
284+
tier_prices {
285+
customer_group_id
286+
qty
287+
percentage_value
288+
website_id
289+
}
290+
tier_prices {
291+
customer_group_id
292+
qty
293+
percentage_value
294+
website_id
295+
}
296+
tier_prices {
297+
customer_group_id
298+
qty
299+
percentage_value
300+
website_id
301+
}
302+
tier_prices {
303+
customer_group_id
304+
qty
305+
percentage_value
306+
website_id
307+
}
308+
tier_prices {
309+
customer_group_id
310+
qty
311+
percentage_value
312+
website_id
313+
}
314+
tier_prices {
315+
customer_group_id
316+
qty
317+
percentage_value
318+
website_id
319+
}
320+
tier_prices {
321+
customer_group_id
322+
qty
323+
percentage_value
324+
website_id
325+
}
266326
new_to_date
267327
new_from_date
268328
tier_price
@@ -330,10 +390,9 @@ public function testQueryComplexityIsLimited()
330390
}
331391
}
332392
}
333-
334393
QUERY;
335394

336-
self::expectExceptionMessageRegExp('/Max query complexity should be 250 but got 252/');
395+
self::expectExceptionMessageRegExp('/Max query complexity should be 300 but got 302/');
337396
$this->graphQlQuery($query);
338397
}
339398

0 commit comments

Comments
 (0)