Curl output not displayed for gremlin query

360 views Asked by At

Trying to execute a query using curl. The output is not displayed on the terminal. Reference used: https://docs.janusgraph.org/basics/server/

Command used on server:


curl -v -POST -H 'Content-type: application/json'  http://localhost:8182 -d '{"gremlin": "g.V().count()"}'

Output:

 * Rebuilt URL to: http://localhost:8182/
 *   Trying 127.0.0.1...
 * Connected to localhost (127.0.0.1) port 8182 (#0)
> POST / HTTP/1.1
> Host: localhost:8182
> User-Agent: curl/7.47.0
> Accept: */*
> Content-type: application/json
> Content-Length: 57
>
 * upload completely sent off: 57 out of 57 bytes

It gets stuck here, hence I terminate it. I want the count displayed on the screen or in a specified file.

1

There are 1 answers

0
ourdaidai On

curl --location --request POST 'localhost:8182' --header 'Content-Type: application/json' --data-raw '{"gremlin":"g.V().count()"}'

Works for me. I think you can check janusgraph's log. See if janusgraph server recived your request.