Interface RateLimiter

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void acquire​(long permits)
      Sleep until the specified number of queries are available.
      long getRate()
      Get current QPS of the rate limiter, with a non-positive rate indicating no limit.
    • Method Detail

      • getRate

        long getRate()
        Get current QPS of the rate limiter, with a non-positive rate indicating no limit.
      • acquire

        void acquire​(long permits)
        Sleep until the specified number of queries are available.