def increment(by: nil, max: nil)
      by ||= @default_increment
      max ||= @max

      value = if max.nil?
        self.connection.incrby(@key, by.to_i).to_i
      else
        ring_increment_script(keys: @key, argv: [by.to_i, max.to_i]).to_i
      end

      return value
    end
def increment(by: nil, max: nil)
      by ||= @default_increment
      max ||= @max

      value = if max.nil?
        self.connection.incrby(@key, by.to_i).to_i
      else
        ring_increment_script(keys: @key, argv: [by.to_i, max.to_i]).to_i
      end

      return value
    end
Increments the counter by the given value. If max is given, will loop around and start again from 0 (will increment by (current_value + by) % max).
 @param [Integer, nil] by defaults to @increment, used to increment the underlying counter
 @param [Integer, nil] max if non-nil, the counter will loop and start over from 0 when it reaches max
 @example
   pry> counter.increment(by: 10, max: 5) # returns 0, since 10 % 5 == 0
   pry> counter.increment(by: 9, max: 5) # returns 4
 @return [Integer] the updated value