summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--jstests/sharding/query/javascript_heap_limit.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/jstests/sharding/query/javascript_heap_limit.js b/jstests/sharding/query/javascript_heap_limit.js
index c08c4fdd778..32762653f8d 100644
--- a/jstests/sharding/query/javascript_heap_limit.js
+++ b/jstests/sharding/query/javascript_heap_limit.js
@@ -27,8 +27,8 @@ function setHeapSizeLimitMB({db, queryLimit, globalLimit}) {
}
function allocateLargeString() {
- const arraySize = 10000000;
- let str = new Array(arraySize).join("x");
+ const arraySize = 1000000;
+ let str = new Array(arraySize).fill(0);
return true;
}