Interface EntityProperties


  • public interface EntityProperties
    Unified interface for dynamic entity-specific dynamic properties, that may change at runtime
    Author:
    [email protected]
    • Method Detail

      • getItemsPerBatchOriginal

        int getItemsPerBatchOriginal()
        Get initially configured batch size.
        Returns:
        batch size
      • isSplitPushWhenRateLimited

        boolean isSplitPushWhenRateLimited()
        Whether we should split batches into smaller ones after getting HTTP 406 response from server.
        Returns:
        true if we should split on pushback
      • getRateLimit

        double getRateLimit()
        Get initially configured rate limit (per second).
        Returns:
        rate limit
      • getRateLimitMaxBurstSeconds

        int getRateLimitMaxBurstSeconds()
        Get max number of burst seconds to allow when rate limiting to smooth out uneven traffic.
        Returns:
        number of seconds
      • getRateLimiter

        com.google.common.util.concurrent.RecyclableRateLimiter getRateLimiter()
        Get specific RecyclableRateLimiter instance.
        Returns:
        rate limiter
      • getFlushThreads

        int getFlushThreads()
        Get the number of worker threads.
        Returns:
        number of threads
      • getPushFlushInterval

        int getPushFlushInterval()
        Get interval between batches (in milliseconds)
        Returns:
        interval between batches
      • getItemsPerBatch

        int getItemsPerBatch()
        Get the maximum allowed number of items per single flush.
        Returns:
        batch size
      • setItemsPerBatch

        void setItemsPerBatch​(@Nullable
                              Integer itemsPerBatch)
        Sets the maximum allowed number of items per single flush.
        Parameters:
        itemsPerBatch - batch size. if null is provided, reverts to originally configured value.
      • getMinBatchSplitSize

        int getMinBatchSplitSize()
        Do not split the batch if its size is less than this value. Only applicable when isSplitPushWhenRateLimited() is true.
        Returns:
        smallest allowed batch size
      • getMemoryBufferLimit

        int getMemoryBufferLimit()
        Max number of items that can stay in memory buffers before spooling to disk. Defaults to 16 * getItemsPerBatch(), minimum size: getItemsPerBatch(). Setting this value lower than default reduces memory usage, but will force the proxy to spool to disk more frequently if you have points arriving at the proxy in short bursts, and/or your network latency is on the higher side.
        Returns:
        memory buffer limit
      • getTaskQueueLevel

        TaskQueueLevel getTaskQueueLevel()
        Get current queueing behavior - defines conditions that trigger queueing.
        Returns:
        queueing behavior level
      • isFeatureDisabled

        boolean isFeatureDisabled()
        Checks whether data flow for this entity type is disabled.
        Returns:
        true if data flow is disabled
      • setFeatureDisabled

        void setFeatureDisabled​(boolean featureDisabled)
        Sets the flag value for "feature disabled" flag.
        Parameters:
        featureDisabled - if "true", data flow for this entity type is disabled.
      • getGlobalProperties

        EntityProperties.GlobalProperties getGlobalProperties()
        Accesses a container with properties shared across all entity types
        Returns:
        global properties container