Enum Class PostgresErrorCode
java.lang.Object
java.lang.Enum<PostgresErrorCode>
org.odpi.openmetadata.adapters.repositoryservices.postgres.repositoryconnector.ffdc.PostgresErrorCode
- All Implemented Interfaces:
Serializable,Comparable<PostgresErrorCode>,Constable,org.odpi.openmetadata.frameworks.auditlog.messagesets.ExceptionMessageSet
public enum PostgresErrorCode
extends Enum<PostgresErrorCode>
implements org.odpi.openmetadata.frameworks.auditlog.messagesets.ExceptionMessageSet
The PostgresErrorCode is used to define first failure data capture (FFDC) for errors that occur when working with
XTDB as an OMRS Metadata Repository. It is used in conjunction with both Checked and Runtime (unchecked) exceptions.
The 5 fields in the enum are:
The 5 fields in the enum are:
- HTTP Error Code - for translating between REST and JAVA - Typically the numbers used are:
- 500 - internal error
- 400 - invalid parameters
- 404 - not found
- Error Message Id - to uniquely identify the message
- Error Message Text - includes placeholder to allow additional values to be captured
- SystemAction - describes the result of the error
- UserAction - describes how a AssetConsumerInterface should correct the error
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionPOSTGRES-REPOSITORY-CONNECTOR-400-003 - The search string {0} is taking over 500 ms to run against a simple stringPOSTGRES-REPOSITORY-CONNECTOR-400-002 - The {0} postgreSQL repository connector has detected an incompatible search property with operator {1}: {2}POSTGRES-REPOSITORY-CONNECTOR-500-006 - The {0} postgreSQL repository connector is not able to use the contents of database schema {1} because this repository is for server {2}POSTGRES-REPOSITORY-CONNECTOR-500-007 - The {0} postgreSQL repository connector is not able to use the contents of database schema {1} because it does not support schema version {2}POSTGRES-REPOSITORY-CONNECTOR-500-005 - The {0} postgreSQL repository connector is not able to use the contents of database schema {1} because this repository is for server {2}POSTGRES-REPOSITORY-CONNECTOR-500-004 - The {0} postgreSQL repository connector detected an invalid value for column {1} during method {2} in mapper {3}; row values are: {4}POSTGRES-REPOSITORY-CONNECTOR-500-002 - The postgreSQL connector is missing {0} value during method {1} in mapper {2}POSTGRES-REPOSITORY-CONNECTOR-500-003 - The {0} postgreSQL repository connector detected a missing value for column {1} during method {2} in mapper {3}; row values are: {4}POSTGRES-REPOSITORY-CONNECTOR-400-001 - The {0} postgreSQL repository connector is running in read-only mode; updates are not allowedPOSTGRES-REPOSITORY-CONNECTOR-500-001 - The {0} postgreSQL connector received an unexpected exception {1} during method {2}; the error message was: {3} -
Method Summary
Modifier and TypeMethodDescriptionorg.odpi.openmetadata.frameworks.auditlog.messagesets.ExceptionMessageDefinitionRetrieve a message definition object for an exception.org.odpi.openmetadata.frameworks.auditlog.messagesets.ExceptionMessageDefinitiongetMessageDefinition(String... params) Retrieve a message definition object for an exception.toString()JSON-style toStringstatic PostgresErrorCodeReturns the enum constant of this class with the specified name.static PostgresErrorCode[]values()Returns an array containing the constants of this enum class, in the order they are declared.Methods inherited from class java.lang.Enum
compareTo, describeConstable, equals, getDeclaringClass, hashCode, name, ordinal, valueOf
-
Enum Constant Details
-
READ_ONLY_MODE
POSTGRES-REPOSITORY-CONNECTOR-400-001 - The {0} postgreSQL repository connector is running in read-only mode; updates are not allowed -
BAD_SEARCH_PROPERTY
POSTGRES-REPOSITORY-CONNECTOR-400-002 - The {0} postgreSQL repository connector has detected an incompatible search property with operator {1}: {2} -
BAD_REGEX
POSTGRES-REPOSITORY-CONNECTOR-400-003 - The search string {0} is taking over 500 ms to run against a simple string -
UNEXPECTED_EXCEPTION
POSTGRES-REPOSITORY-CONNECTOR-500-001 - The {0} postgreSQL connector received an unexpected exception {1} during method {2}; the error message was: {3} -
MISSING_MAPPING_VALUE
POSTGRES-REPOSITORY-CONNECTOR-500-002 - The postgreSQL connector is missing {0} value during method {1} in mapper {2} -
MISSING_REPOSITORY_VALUE
POSTGRES-REPOSITORY-CONNECTOR-500-003 - The {0} postgreSQL repository connector detected a missing value for column {1} during method {2} in mapper {3}; row values are: {4} -
INVALID_REPOSITORY_VALUE
POSTGRES-REPOSITORY-CONNECTOR-500-004 - The {0} postgreSQL repository connector detected an invalid value for column {1} during method {2} in mapper {3}; row values are: {4} -
CONTROL_SERVER_MISMATCH
POSTGRES-REPOSITORY-CONNECTOR-500-005 - The {0} postgreSQL repository connector is not able to use the contents of database schema {1} because this repository is for server {2} -
CONTROL_MC_ID_MISMATCH
POSTGRES-REPOSITORY-CONNECTOR-500-006 - The {0} postgreSQL repository connector is not able to use the contents of database schema {1} because this repository is for server {2} -
CONTROL_SCHEMA_VERSION_MISMATCH
POSTGRES-REPOSITORY-CONNECTOR-500-007 - The {0} postgreSQL repository connector is not able to use the contents of database schema {1} because it does not support schema version {2}
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
getMessageDefinition
public org.odpi.openmetadata.frameworks.auditlog.messagesets.ExceptionMessageDefinition getMessageDefinition()Retrieve a message definition object for an exception. This method is used when there are no message inserts.- Specified by:
getMessageDefinitionin interfaceorg.odpi.openmetadata.frameworks.auditlog.messagesets.ExceptionMessageSet- Returns:
- message definition object.
-
getMessageDefinition
public org.odpi.openmetadata.frameworks.auditlog.messagesets.ExceptionMessageDefinition getMessageDefinition(String... params) Retrieve a message definition object for an exception. This method is used when there are values to be inserted into the message.- Specified by:
getMessageDefinitionin interfaceorg.odpi.openmetadata.frameworks.auditlog.messagesets.ExceptionMessageSet- Parameters:
params- array of parameters (all strings). They are inserted into the message according to the numbering in the message text.- Returns:
- message definition object.
-
toString
JSON-style toString- Overrides:
toStringin classEnum<PostgresErrorCode>- Returns:
- string of property names and values for this enum
-