Interface StatisticsMaintenanceOnHost
- All Superinterfaces:
io.github.mfvanek.pg.connection.HostAware
,StatisticsAware
- All Known Implementing Classes:
StatisticsMaintenanceOnHostImpl
public interface StatisticsMaintenanceOnHost
extends StatisticsAware, io.github.mfvanek.pg.connection.HostAware
An entry point for managing statistics on the specified host.
- See Also:
-
HostAware
-
Method Summary
Modifier and TypeMethodDescriptionGets time at which database statistics were last reset on current host.boolean
Resets all statistics counters for the current database on current host to zero.Methods inherited from interface io.github.mfvanek.pg.connection.HostAware
getHost
-
Method Details
-
resetStatistics
boolean resetStatistics()Resets all statistics counters for the current database on current host to zero.Note: superuser privileges are required.
- Specified by:
resetStatistics
in interfaceStatisticsAware
- Returns:
- true if the operation is successful
- See Also:
-
getLastStatsResetTimestamp
Gets time at which database statistics were last reset on current host.- Specified by:
getLastStatsResetTimestamp
in interfaceStatisticsAware
- Returns:
Optional
of null or time at which database statistics were last reset.
-