Class CachingOperationInvoker

    • Method Detail

      • getTimeToLive

        public long getTimeToLive()
        Return the maximum time in milliseconds that a response can be cached.
        Returns:
        the time to live of a response
      • apply

        public static OperationInvoker apply​(OperationInvoker invoker,
                                             long timeToLive)
        Apply caching configuration when appropriate to the given invoker.
        Parameters:
        invoker - the invoker to wrap
        timeToLive - the maximum time in milliseconds that a response can be cached
        Returns:
        a caching version of the invoker or the original instance if caching is not required