Interface RotationPolicy<T extends LogRotationPolicyCfg>

    • Method Detail

      • initializeLogRotationPolicy

        void initializeLogRotationPolicy​(T config)
                                  throws ConfigException,
                                         InitializationException
        Initializes this log rotation policy based on the information in the provided rotation policy configuration.
        Parameters:
        config - The rotation policy configuration that contains the information to use to initialize this policy.
        Throws:
        ConfigException - If an unrecoverable problem arises in the process of performing the initialization as a result of the server configuration.
        InitializationException - If a problem occurs during initialization that is not related to the server configuration.
      • rotateFile

        boolean rotateFile​(RotatableLogFile writer)
        This method indicates if the log file should be rotated or not.
        Parameters:
        writer - the file writer to be checked.
        Returns:
        true if the log file should be rotated, false otherwise.