通过curl运行查询时,couchbase查询节点变得无响应

问题描述 投票:0回答:1

我通过curl在我的couchbase查询节点上运行查询,注意到查询节点上的RAM使用率非常快地达到97%,然后节点变得无响应并且curl请求因错误而终止:curl: (18) transfer closed with outstanding read data remaining

下面是我的卷曲请求:

curl http://<ip>:8093/query/service -u Administrator:<password> --data-urlencode 'statement=SELECT customerId,(ARRAY v.value FOR v IN p.events WHEN v.type = "Credit" AND v.funder like "TM%" END) AS credits FROM default AS p WHERE p.type = "account" AND p.schemeId = "some-scheme" AND (ANY e IN p.events SATISFIES e.funder LIKE "TM%" AND e.type = "Credit" END)' > /tmp/results.json

很明显RAM正在被完全使用,机器暂时冻结。有没有办法限制查询服务的缓冲?或者是别的什么?

curl couchbase n1ql
1个回答
0
投票

你收到了数据的任何部分吗?我最好的猜测是你的查询处理大量数据并且有一些阻塞操作,比如排序或聚合,需要在产生任何输出之前消耗所有输入。使用EXPLAIN检查查询中的内容。

© www.soinside.com 2019 - 2024. All rights reserved.