@Singleton @Requires(property="micronaut.multitenancy.tenantwriter.httpheader.enabled") @Requires(beans=io.micronaut.multitenancy.writer.HttpHeaderTenantWriterConfiguration.class) public class HttpHeaderTenantWriter extends Object implements TenantWriter
Modifier and Type | Field and Description |
---|---|
protected io.micronaut.multitenancy.writer.HttpHeaderTenantWriterConfiguration |
httpHeaderTenantWriterConfiguration |
PREFIX
Constructor and Description |
---|
HttpHeaderTenantWriter(io.micronaut.multitenancy.writer.HttpHeaderTenantWriterConfiguration httpHeaderTenantWriterConfiguration) |
Modifier and Type | Method and Description |
---|---|
protected String |
getHeaderName() |
void |
writeTenant(MutableHttpRequest<?> request,
Serializable tenant)
Writes the token to the request.
|
protected final io.micronaut.multitenancy.writer.HttpHeaderTenantWriterConfiguration httpHeaderTenantWriterConfiguration
public HttpHeaderTenantWriter(io.micronaut.multitenancy.writer.HttpHeaderTenantWriterConfiguration httpHeaderTenantWriterConfiguration)
httpHeaderTenantWriterConfiguration
- The HttpHeaderTenantWriter
configurationprotected String getHeaderName()
public void writeTenant(MutableHttpRequest<?> request, Serializable tenant)
writeTenant
in interface TenantWriter
request
- The MutableHttpRequest
instancetenant
- Tenant Id