Class OpenIdHelper

java.lang.Object
uk.co.spudsoft.jwtvalidatorvertx.impl.OpenIdHelper

public class OpenIdHelper extends Object
Helper class for performing OpenID Discovery and JWKS requests.
Author:
njt
  • Constructor Details

    • OpenIdHelper

      public OpenIdHelper(io.vertx.ext.web.client.WebClient webClient, long defaultCacheDurationS)
      Constructor.
      Parameters:
      webClient - The Vert.x WebClient to use for making HTTP requests.
      defaultCacheDurationS - The default time that the caller should cache results.
  • Method Details

    • get

      public io.vertx.core.Future<AsyncLoadingCache.TimedObject<io.vertx.core.json.JsonObject>> get(String url)
      Get a JsonObject from a URL and return it as Future with an expiry time.
      Parameters:
      url - The URL to be got.
      Returns:
      A TimedObject containing JSON from the URL and an expiry time based on the Cache-Control max-age header.