Class TrackingSlotSupplier<SI extends SlotInfo>

  • Type Parameters:
    SI - The slot info type

    public class TrackingSlotSupplier<SI extends SlotInfo>
    extends java.lang.Object
    Wraps a slot supplier and supplements it with additional tracking information that is useful to provide to all implementations. This type is used internally rather than SlotSupplier directly.
    • Constructor Detail

      • TrackingSlotSupplier

        public TrackingSlotSupplier​(SlotSupplier<SI> inner,
                                    com.uber.m3.tally.Scope metricsScope)
    • Method Detail

      • reserveSlot

        public SlotPermit reserveSlot​(SlotReservationData dat)
                               throws java.lang.InterruptedException
        Throws:
        java.lang.InterruptedException
      • markSlotUsed

        public void markSlotUsed​(SI slotInfo,
                                 SlotPermit permit)
      • maximumSlots

        public java.util.Optional<java.lang.Integer> maximumSlots()
      • getIssuedSlots

        public int getIssuedSlots()