Class H2SqlStatements
- java.lang.Object
-
- io.apicurio.registry.storage.impl.sql.CommonSqlStatements
-
- io.apicurio.registry.storage.impl.sql.H2SqlStatements
-
- All Implemented Interfaces:
SqlStatements
public class H2SqlStatements extends CommonSqlStatements
H2 implementation of the sql statements interface. Provides sql statements that are specific to H2, where applicable.- Author:
- eric.wittmann@gmail.com
-
-
Constructor Summary
Constructors Constructor Description H2SqlStatements()Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringdbType()Gets the database type associated with these statements.StringgetNextSequenceValue()StringisDatabaseInitialized()A statement that returns 'true' if the database has already been initialized.booleanisForeignKeyViolation(Exception error)Returns true if the given exception represents a foreign key violation.booleanisPrimaryKeyViolation(Exception error)Returns true if the given exception represents a primary key violation.StringresetSequenceValue()StringupsertContent()A statement to "upsert" a row in the "content" table.StringupsertLogConfiguration()A statement to "upsert" a row in the "logconfiguration" table-
Methods inherited from class io.apicurio.registry.storage.impl.sql.CommonSqlStatements
autoUpdateVersionForGlobalId, databaseInitialization, databaseUpgrade, deleteAllArtifactRules, deleteAllArtifacts, deleteAllContent, deleteAllGroups, deleteAllLabels, deleteAllOrphanedContent, deleteAllProperties, deleteAllRoleMappings, deleteAllVersions, deleteArtifact, deleteArtifactRule, deleteArtifactRules, deleteArtifactRulesByGroupId, deleteArtifactsByGroupId, deleteDownload, deleteExpiredDownloads, deleteGlobalRule, deleteGlobalRules, deleteGroup, deleteLabels, deleteLabelsByGlobalId, deleteLabelsByGroupId, deleteLogConfiguration, deleteProperties, deletePropertiesByGlobalId, deletePropertiesByGroupId, deleteRoleMapping, deleteVersion, deleteVersionLabels, deleteVersionProperties, deleteVersions, deleteVersionsByGroupId, exportArtifactRules, exportArtifactVersions, exportContent, exportGlobalRules, exportGroups, getDatabaseVersion, importArtifactRule, importArtifactVersion, importContent, importGlobalRule, importGroup, insertArtifact, insertArtifactRule, insertDownload, insertGlobalRule, insertGroup, insertLabel, insertProperty, insertRoleMapping, insertSequenceValue, insertVersion, selectAllArtifactCount, selectAllArtifactVersions, selectAllArtifactVersionsCount, selectAllLogConfigurations, selectArtifactCountById, selectArtifactIds, selectArtifactMetaDataByGlobalId, selectArtifactRuleByType, selectArtifactRuleCountByType, selectArtifactRules, selectArtifactVersionContent, selectArtifactVersionContentByGlobalId, selectArtifactVersionMetaData, selectArtifactVersionMetaDataByCanonicalHash, selectArtifactVersionMetaDataByContentHash, selectArtifactVersionMetaDataByContentId, selectArtifactVersionMetaDataByGlobalId, selectArtifactVersions, selectContentByContentHash, selectContentById, selectContentCountByHash, selectContentExists, selectContentIdByHash, selectCurrentSequenceValue, selectDownloadContext, selectGlobalIdExists, selectGlobalRuleByType, selectGlobalRuleCountByType, selectGlobalRules, selectGroupByGroupId, selectGroups, selectLatestArtifactContent, selectLatestArtifactMetaData, selectLogConfigurationByLogger, selectMaxContentId, selectMaxGlobalId, selectRoleByPrincipalId, selectRoleMappingByPrincipalId, selectRoleMappingCountByPrincipal, selectRoleMappings, selectTotalArtifactVersionsCount, updateArtifactLatest, updateArtifactLatestGlobalId, updateArtifactRule, updateArtifactVersionMetaData, updateArtifactVersionState, updateContentCanonicalHash, updateGlobalRule, updateGroup, updateRoleMapping
-
-
-
-
Method Detail
-
dbType
public String dbType()
Description copied from interface:SqlStatementsGets the database type associated with these statements.- See Also:
SqlStatements.dbType()
-
isPrimaryKeyViolation
public boolean isPrimaryKeyViolation(Exception error)
Description copied from interface:SqlStatementsReturns true if the given exception represents a primary key violation.
-
isForeignKeyViolation
public boolean isForeignKeyViolation(Exception error)
Description copied from interface:SqlStatementsReturns true if the given exception represents a foreign key violation.
-
isDatabaseInitialized
public String isDatabaseInitialized()
Description copied from interface:SqlStatementsA statement that returns 'true' if the database has already been initialized.- See Also:
io.apicurio.registry.storage.impl.sql.SqlStatements.core.storage.jdbc.ISqlStatements#isDatabaseInitialized()
-
upsertContent
public String upsertContent()
Description copied from interface:SqlStatementsA statement to "upsert" a row in the "content" table.- See Also:
SqlStatements.upsertContent()
-
upsertLogConfiguration
public String upsertLogConfiguration()
Description copied from interface:SqlStatementsA statement to "upsert" a row in the "logconfiguration" table- See Also:
SqlStatements.upsertLogConfiguration()
-
getNextSequenceValue
public String getNextSequenceValue()
- See Also:
SqlStatements.getNextSequenceValue()
-
resetSequenceValue
public String resetSequenceValue()
- See Also:
SqlStatements.resetSequenceValue()
-
-