Interface HttpRequestTenantResolver

All Known Implementing Classes:
AbstractSubdomainTenantResolver, CookieTenantResolver, HttpHeaderTenantResolver, InternetDomainNameSubdomainTenantResolver, PrincipalTenantResolver, PublicSuffixListSubdomainTenantResolver, SessionTenantResolver, SubdomainTenantResolver
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface HttpRequestTenantResolver
An interface for multi-tenant aware applications which resolve the current identifier for the current request.
Since:
2.1.2
Author:
Sergio del Amo
  • Method Summary

    Modifier and Type
    Method
    Description
    @NonNull Serializable
    resolveTenantIdentifier(@NonNull io.micronaut.http.HttpRequest<?> request)
    Resolves the current tenant identifier.
  • Method Details

    • resolveTenantIdentifier

      @NonNull @NonNull Serializable resolveTenantIdentifier(@NonNull @NonNull io.micronaut.http.HttpRequest<?> request) throws TenantNotFoundException
      Resolves the current tenant identifier.
      Parameters:
      request - The HTTP request
      Returns:
      The tenant identifier
      Throws:
      TenantNotFoundException - if tenant not found