Annotation Type RequestTimeout


@Target(METHOD) @Retention(RUNTIME) public @interface RequestTimeout
Overrides global request timeout for this endpoint.

 @Client
 interface CustomerApi {
   @Get("/{id}")
   @RequestTimeout(value = 1, ChronoUnit.SECONDS)
   Customer getById(long id);
 }

 
  • Required Element Summary

    Required Elements
    Modifier and Type
    Required Element
    Description
    long
    How long the timeout should be
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    Unit of time of the timeout value
  • Element Details

    • value

      long value
      How long the timeout should be
    • chronoUnit

      ChronoUnit chronoUnit
      Unit of time of the timeout value
      Default:
      MILLIS