Module bus.http

Class RealCall.AsyncCall

java.lang.Object
org.miaixz.bus.http.metric.NamedRunnable
org.miaixz.bus.http.RealCall.AsyncCall
All Implemented Interfaces:
Runnable
Enclosing class:
RealCall

public final class RealCall.AsyncCall extends NamedRunnable
An asynchronous call that can be executed on a background thread.
  • Method Details

    • callsPerHost

      public AtomicInteger callsPerHost()
      Returns the number of calls per host.
      Returns:
      The number of calls per host.
    • reuseCallsPerHostFrom

      public void reuseCallsPerHostFrom(RealCall.AsyncCall other)
      Reuses the host call count from another asynchronous call.
      Parameters:
      other - The other asynchronous call.
    • host

      public String host()
      Returns the hostname for this call.
      Returns:
      The hostname.
    • get

      public RealCall get()
      Returns the RealCall instance for this asynchronous call.
      Returns:
      The RealCall instance.
    • executeOn

      public void executeOn(ExecutorService executorService)
      Executes this asynchronous call on the given executor service.
      Parameters:
      executorService - The executor service.
    • execute

      protected void execute()
      Executes the asynchronous call.
      Specified by:
      execute in class NamedRunnable