Skip to content

Commit 41ed696

Browse files
committed
Documentation of the additional GQL error info in the query log
1 parent a2bffb1 commit 41ed696

File tree

1 file changed

+48
-0
lines changed

1 file changed

+48
-0
lines changed

modules/ROOT/pages/monitoring/logging.adoc

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1239,6 +1239,10 @@ Included when xref:configuration/configuration-settings.adoc#config_db.logs.quer
12391239
| Reason for failure.
12401240
Included when applicable.
12411241

1242+
| errorInfo
1243+
| GQL error information as a JSON object.
1244+
See xref:monitoring/logging.adoc#_gql_error_information[GQL error information] for what is contained in this errorInfo JSON object.
1245+
12421246
| transactionId
12431247
| The transaction ID of the running query.
12441248

@@ -1272,3 +1276,47 @@ Either same as `authenticatedUser` or an impersonated user.
12721276
| transactionId
12731277
| ID of the transaction.
12741278
|===
1279+
1280+
==== GQL error information
1281+
1282+
The GQL error information is included in the querylog as the field `errorInfo`.
1283+
The JSON object `errorInfo` can contain the following elements:
1284+
1285+
* `GQLSTATUS:` A 5 character long alpha-numeric code which identifies the error.
1286+
* `statusDescription:` A message describing the error.
1287+
* `classification:` The type of error, representing a division of client errors, transient errors and database errors.
1288+
* `position:` The position (a JSON object containing a field for `column`, `offset` and `line`) in the query where this error occurred.
1289+
* `cause:` This is a JSON object containing the errorInfo JSON object of the cause of the current errorInfo JSON object.
1290+
1291+
Below are examples of the `errorInfo` JSON object:
1292+
[source%linenums,xml,options="nowrap",highlight=4]
1293+
----
1294+
...
1295+
"errorInfo": {
1296+
"GQLSTATUS": "51N66",
1297+
"statusDescription": "error: system configuration or operation exception - resource exhaustion. Insufficient resources to complete the request.",
1298+
"cause": {
1299+
"GQLSTATUS": "51N55",
1300+
"statusDescription": "error: system configuration or operation exception - cannot create additional database. Failed to create the database `db10`. The limit of databases is reached. Either increase the limit using the config setting dbms.max_databases or drop a database.",
1301+
"classification": "DATABASE_ERROR"
1302+
},
1303+
"classification": "DATABASE_ERROR"
1304+
},
1305+
...
1306+
----
1307+
1308+
----
1309+
...
1310+
"errorInfo": {
1311+
"GQLSTATUS": "42N62",
1312+
"statusDescription": "error: syntax error or access rule violation - variable not defined. Variable `m` not defined.",
1313+
"position": {
1314+
"column": 18,
1315+
"offset": 17,
1316+
"line": 1
1317+
},
1318+
"classification": "CLIENT_ERROR"
1319+
},
1320+
"query": "MATCH (n) RETURN m",
1321+
...
1322+
----

0 commit comments

Comments
 (0)