Introduces GQL-compliant status objects to the ResultSummary.
GqlStatusObject is a GQL-compliant Notification object and status of query execution, this new object includes GqlStatus and StatusDescription.
ResultSummary.GqlStatusObjects() always contains at least 1 status representing the Success, No Data or Omitted Result.
The GqlStatusObjects will be presented in the following order:
A “no data” (02xxx) has precedence over a warning;
A warning (01xxx) has precedence over a success.
A success (00xxx) has precedence over anything informational (03xxx)
Migration from Notification
Most properties in Notification exist in the new GqlStatusObject, except Code and Title.
The GqlStatusObject.GqlStatus is equivalent to Code in Notification, but with values compliant with GQL.
The properties GqlStatusObject.Classification and GqlStatusObject.RawClassification are equivalent to Notification.Category and Notification.RawCategory. The name change is needed because Category has a different meaning in GQL.
Usage
Disabling GqlStatusObjects can be done in the same way as disabling Notifications. However, non-notification status can not be filtered (such as Success or No Data):
Iterating through GqlStatusObjects is also done in the same way as Notifications:
gqlStatusObjects := result.Summary.GqlStatusObjects()
for _, gqlStatusObject := range gqlStatusObjects {
fmt.Printf(gqlStatusObject.GqlStatus())
fmt.Printf(gqlStatusObject.StatusDescription())
fmt.Printf(gqlStatusObject.DiagnosticRecord())
// and so on
}
Deprecations
neo4j.NotificationSeverity please use notifications.NotificationSeverity directly.
neo4j.Warning please use notifications.Warning directly.
neo4j.Information please use notifications.Information directly.
neo4j.UnknownSeverity please use notifications.UnknownSeverity directly.
neo4j.NotificationCategory please use notifications.NotificationCategory directly.
neo4j.Hint please use notifications.Hint directly.
neo4j.Unrecognized please use notifications.Unrecognized directly.
neo4j.Unsupported please use notifications.Unsupported directly.
neo4j.Performance please use notifications.Performance directly.
neo4j.Deprecation please use notifications.Deprecation directly.
neo4j.Generic please use notifications.Generic directly.
neo4j.Security please use notifications.Security directly.
neo4j.Topology please use notifications.Topology directly.
neo4j.UnknownCategory please use notifications.Unknown directly.
⚠️ This API is released as preview.
Introduces GQL-compliant status objects to the
ResultSummary
.GqlStatusObject
is a GQL-compliantNotification
object and status of query execution, this new object includesGqlStatus
andStatusDescription
.ResultSummary.GqlStatusObjects()
always contains at least 1 status representing theSuccess
,No Data
orOmitted Result
.The GqlStatusObjects will be presented in the following order:
02xxx
) has precedence over a warning;01xxx
) has precedence over a success.00xxx
) has precedence over anything informational (03xxx
)Migration from Notification
Most properties in
Notification
exist in the newGqlStatusObject
, exceptCode
andTitle
. TheGqlStatusObject.GqlStatus
is equivalent toCode
inNotification
, but with values compliant with GQL. The propertiesGqlStatusObject.Classification
andGqlStatusObject.RawClassification
are equivalent toNotification.Category
andNotification.RawCategory
. The name change is needed because Category has a different meaning in GQL.Usage
Disabling GqlStatusObjects can be done in the same way as disabling Notifications. However, non-notification status can not be filtered (such as Success or No Data):
Iterating through GqlStatusObjects is also done in the same way as Notifications:
Deprecations
neo4j.NotificationSeverity
please usenotifications.NotificationSeverity
directly.neo4j.Warning
please usenotifications.Warning
directly.neo4j.Information
please usenotifications.Information
directly.neo4j.UnknownSeverity
please usenotifications.UnknownSeverity
directly.neo4j.NotificationCategory
please usenotifications.NotificationCategory
directly.neo4j.Hint
please usenotifications.Hint
directly.neo4j.Unrecognized
please usenotifications.Unrecognized
directly.neo4j.Unsupported
please usenotifications.Unsupported
directly.neo4j.Performance
please usenotifications.Performance
directly.neo4j.Deprecation
please usenotifications.Deprecation
directly.neo4j.Generic
please usenotifications.Generic
directly.neo4j.Security
please usenotifications.Security
directly.neo4j.Topology
please usenotifications.Topology
directly.neo4j.UnknownCategory
please usenotifications.Unknown
directly.