Package io.github.mfvanek.pg.checks.host
Class InvalidIndexesCheckOnHost
java.lang.Object
io.github.mfvanek.pg.checks.host.InvalidIndexesCheckOnHost
- All Implemented Interfaces:
DatabaseCheckOnHost<io.github.mfvanek.pg.model.index.Index>
,DiagnosticAware
,RawTypeAware<io.github.mfvanek.pg.model.index.Index>
,io.github.mfvanek.pg.connection.HostAware
Check for invalid (broken) indexes on a specific host.
- Since:
- 0.6.0
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionInvalidIndexesCheckOnHost
(io.github.mfvanek.pg.connection.PgConnection pgConnection) -
Method Summary
Modifier and TypeMethodDescriptionList<io.github.mfvanek.pg.model.index.Index>
check
(io.github.mfvanek.pg.model.PgContext pgContext) Returns invalid (broken) indexes in the specified schema.protected List<io.github.mfvanek.pg.model.index.Index>
executeQuery
(io.github.mfvanek.pg.model.PgContext pgContext, ResultSetExtractor<io.github.mfvanek.pg.model.index.Index> rse) Gets the diagnostic - a rule related to the check.io.github.mfvanek.pg.connection.PgHost
getHost()
Class<io.github.mfvanek.pg.model.index.Index>
getType()
Gets original java type.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.github.mfvanek.pg.common.maintenance.DatabaseCheckOnHost
check
-
Field Details
-
TABLE_NAME
- See Also:
-
INDEX_NAME
- See Also:
-
TABLE_SIZE
- See Also:
-
INDEX_SIZE
- See Also:
-
BLOAT_SIZE
- See Also:
-
BLOAT_PERCENTAGE
- See Also:
-
-
Constructor Details
-
InvalidIndexesCheckOnHost
public InvalidIndexesCheckOnHost(@Nonnull io.github.mfvanek.pg.connection.PgConnection pgConnection)
-
-
Method Details
-
check
@Nonnull public List<io.github.mfvanek.pg.model.index.Index> check(@Nonnull io.github.mfvanek.pg.model.PgContext pgContext) Returns invalid (broken) indexes in the specified schema.- Parameters:
pgContext
- check's context with the specified schema- Returns:
- list of invalid indexes
- See Also:
-
Index
-
getType
Gets original java type.- Specified by:
getType
in interfaceRawTypeAware<T extends io.github.mfvanek.pg.model.DbObject>
- Returns:
- java type representing database object
-
getDiagnostic
Gets the diagnostic - a rule related to the check.- Specified by:
getDiagnostic
in interfaceDiagnosticAware
- Returns:
- diagnostic
- See Also:
-
getHost
@Nonnull public io.github.mfvanek.pg.connection.PgHost getHost()- Specified by:
getHost
in interfaceio.github.mfvanek.pg.connection.HostAware
-
executeQuery
@Nonnull protected List<io.github.mfvanek.pg.model.index.Index> executeQuery(@Nonnull io.github.mfvanek.pg.model.PgContext pgContext, @Nonnull ResultSetExtractor<io.github.mfvanek.pg.model.index.Index> rse)
-