Package org.h2.jmx

Interface DatabaseInfoMBean

  • All Known Implementing Classes:
    DatabaseInfo

    public interface DatabaseInfoMBean
    Information and management operations for the given database.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      int getCacheSize()
      The current cache size in KB.
      int getCacheSizeMax()
      The maximum cache size in KB.
      long getFileReadCount()
      The file read count since the database was opened.
      long getFileSize()
      The database file size in KB.
      long getFileWriteCount()
      The number of write operations since the database was opened.
      java.lang.String getMode()
      The database compatibility mode (REGULAR if no compatibility mode is used).
      int getTraceLevel()
      The trace level (0 disabled, 1 error, 2 info, 3 debug).
      java.lang.String getVersion()
      The database version.
      boolean isExclusive()
      Is the database open in exclusive mode?
      boolean isReadOnly()
      Is the database read-only?
      java.lang.String listSessions()
      List sessions, including the queries that are in progress, and locked tables.
      java.lang.String listSettings()
      List the database settings.
      void setCacheSizeMax​(int kb)
      Change the maximum size.
      void setTraceLevel​(int level)
      Set the trace level.
    • Method Detail

      • isExclusive

        boolean isExclusive()
        Is the database open in exclusive mode?
        Returns:
        true if the database is open in exclusive mode, false otherwise
      • isReadOnly

        boolean isReadOnly()
        Is the database read-only?
        Returns:
        true if the database is read-only, false otherwise
      • getMode

        java.lang.String getMode()
        The database compatibility mode (REGULAR if no compatibility mode is used).
        Returns:
        the database mode
      • getFileWriteCount

        long getFileWriteCount()
        The number of write operations since the database was opened.
        Returns:
        the write count
      • getFileReadCount

        long getFileReadCount()
        The file read count since the database was opened.
        Returns:
        the read count
      • getFileSize

        long getFileSize()
        The database file size in KB.
        Returns:
        the number of pages
      • getCacheSizeMax

        int getCacheSizeMax()
        The maximum cache size in KB.
        Returns:
        the maximum size
      • setCacheSizeMax

        void setCacheSizeMax​(int kb)
        Change the maximum size.
        Parameters:
        kb - the cache size in KB.
      • getCacheSize

        int getCacheSize()
        The current cache size in KB.
        Returns:
        the current size
      • getVersion

        java.lang.String getVersion()
        The database version.
        Returns:
        the version
      • getTraceLevel

        int getTraceLevel()
        The trace level (0 disabled, 1 error, 2 info, 3 debug).
        Returns:
        the level
      • setTraceLevel

        void setTraceLevel​(int level)
        Set the trace level.
        Parameters:
        level - the new value
      • listSettings

        java.lang.String listSettings()
        List the database settings.
        Returns:
        the database settings
      • listSessions

        java.lang.String listSessions()
        List sessions, including the queries that are in progress, and locked tables.
        Returns:
        information about the sessions