2

I am just trying to kill query which is stuck but it throws me a error.

127.0.0.1:8529@testapp> require("org/arangodb/aql/queries").kill("2418");

JavaScript exception in file '/usr/share/arangodb3/js/client/modules/@arangodb/arangosh.js' at 100,7: ArangoError 1591: cannot kill query '2418' ! throw error; ! ^ stacktrace: ArangoError: cannot kill query '2418' at Object.exports.checkRequestResult (/usr/share/arangodb3/js/client/modules/@arangodb/arangosh.js:98:21) at Object.exports.kill (/usr/share/arangodb3/js/client/modules/@arangodb/aql/queries.js:107:12) at :1:37

Sushil Sharma
  • 2,231
  • 3
  • 23
  • 48
vinay
  • 21
  • 3

1 Answers1

2

Apparently the query was not killed, but this is not necessarily something to worry about. For example, "ArangoError 1591" (as seen in the above error details) will be raised if no such query was found running in the server when the kill command was running.

There are the following two reasons for this:

  • there was no such query with the specified id (query id typo in "kill" command)
  • the query was already over when the "kill" command was executed

The latter case is the most probable. There may always be a situation in which a query is found running for a long time, so there is the decision to kill it. But the query may happen to finish before the kill command is actually executed, and the result in this case will also be an error, precisely error 1591 (query not found).

stj
  • 8,677
  • 15
  • 32