Class CompactionStrategy

    • Constructor Detail

      • CompactionStrategy

        public CompactionStrategy()
        Deprecated, for removal: This API element is subject to removal in a future version.
    • Method Detail

      • init

        public void init​(Map<String,​String> options)
        Deprecated, for removal: This API element is subject to removal in a future version.
        The settings for the compaction strategy pulled from zookeeper. The table.compacations.major.strategy.opts part of the setting will be removed.
      • gatherInformation

        public void gatherInformation​(MajorCompactionRequest request)
                               throws IOException
        Deprecated, for removal: This API element is subject to removal in a future version.
        Called prior to obtaining the tablet lock, useful for examining metadata or indexes. State collected during this method will be available during the call the getCompactionPlan(MajorCompactionRequest).
        Parameters:
        request - basic details about the tablet
        Throws:
        IOException
      • getCompactionPlan

        public abstract CompactionPlan getCompactionPlan​(MajorCompactionRequest request)
                                                  throws IOException
        Deprecated, for removal: This API element is subject to removal in a future version.
        Get the plan for compacting a tablets files. Called while holding the tablet lock, so it should not be doing any blocking.

        Since no blocking should be done in this method, then its unexpected that this method will throw IOException. However since its in the API, it can not be easily removed.

        Parameters:
        request - basic details about the tablet
        Returns:
        the plan for a major compaction, or null to cancel the compaction.
        Throws:
        IOException