Neo4jError
Extends:
Class for all errors thrown/returned by the driver.
Static Method Summary
Static Public Methods | ||
public static |
isRetriable(error: object | undefined | null): boolean this method was deprecated. members using the spelling 'retriable' will be removed in 7.0. Use {@link isRetryable} instead.
Verifies if the given error is retriable. |
|
public static |
isRetryable(error: object | undefined | null): boolean Verifies if the given error is retryable. |
Constructor Summary
Public Constructor | ||
public |
constructor(message: string, code: string, gqlStatus: string, gqlStatusDescription: string, diagnosticRecord: DiagnosticRecord, cause: Error) |
Member Summary
Public Members | ||
public |
code: string The Neo4j Error code |
|
public |
name: string The name of the type of error. |
|
public |
retriable: boolean this member was deprecated. members using the spelling 'retriable' will be removed in 7.0. Use {@link retryable} instead.
If the error is considered retriable. |
|
public |
retryable: boolean If the error is considered retryable. |
Inherited Summary
From class GQLError | ||
public get |
diagnosticRecordAsJsonString: string The json string representation of the diagnostic record. |
|
public |
cause: Error? Optional, nested error which caused the error |
|
public |
The GQL error classification, extracted from the diagnostic record |
|
public |
diagnosticRecord: DiagnosticRecord The GQL diagnostic record |
|
public |
gqlStatus: string The GQL Status code |
|
public |
gqlStatusDescription: string The GQL Status Description |
|
public |
name: string Represents the name for the type of error, inherited from base JavaScript Error. |
|
public |
rawClassification: string The GQL error classification, extracted from the diagnostic record as a raw string |
|
public |
containsGqlCause(gqlStatus: string): boolean Returns whether a given GqlStatus code can be found in the cause chain of the error (including the error itself). |
|
public |
findByGqlStatus(gqlStatus: string): GQLError | Neo4jError | undefined Returns the first error in the cause chain (including the error itself) with a given GqlStatus code. |
Static Public Methods
public static isRetriable(error: object | undefined | null): boolean source
Verifies if the given error is retriable.
Params:
Name | Type | Attribute | Description |
error | object | undefined | null | the error object |
Return:
boolean | true if the error is retriable |
public static isRetryable(error: object | undefined | null): boolean source
Verifies if the given error is retryable.
Params:
Name | Type | Attribute | Description |
error | object | undefined | null | the error object |
Return:
boolean | true if the error is retryable |
Public Constructors
public constructor(message: string, code: string, gqlStatus: string, gqlStatusDescription: string, diagnosticRecord: DiagnosticRecord, cause: Error) source
Override:
GQLError#constructorParams:
Name | Type | Attribute | Description |
message | string | the error message |
|
code | string | Optional error code. Will be populated when error originates in the database. |
|
gqlStatus | string | the GQL status code of the error |
|
gqlStatusDescription | string | the GQL status description of the error |
|
diagnosticRecord | DiagnosticRecord | the error diagnostic record |
|
cause | Error | Optional nested error, the cause of the error |
Public Members
public retriable: boolean source
If the error is considered retriable. This does not apply when running auto-commit transactions using Session#run
public retryable: boolean source
If the error is considered retryable. This does not apply when running auto-commit transactions using Session#run