OpenTSDB curl post问题

时间:2016-04-26 12:12:42

标签: curl opentsdb

我使用以下curl命令将指标推送到opentsdb

curl -X POST --data-binary gzip.json --header "Content-Type: application/json" --header "Content-Encoding: gzip" http://mycloud:xxxx/api/put?details

并获得

curl: (52) Empty reply from server

opentsdb启动并运行,我也可以使用/api/query/进行查询。你能确定哪个部分我错了吗?

1 个答案:

答案 0 :(得分:1)

卷曲调用似乎没问题,只有一件事 - 将@与数据@gzip.json

一起使用

您的电话将是:

curl -X POST --data-binary "@gzip.json" --header "Content-Type: application/json" --header "Content-Encoding: gzip" http://mycloud:xxxx/api/put?details

来源:Compressed Request section