Class KafkaSchemaRegistryConfigurationBuilder
- Namespace
- Silverback.Messaging.Configuration.Kafka.SchemaRegistry
- Assembly
- Silverback.Integration.Kafka.SchemaRegistry.dll
Builds the KafkaSchemaRegistryConfiguration.
public class KafkaSchemaRegistryConfigurationBuilder
- Inheritance
-
KafkaSchemaRegistryConfigurationBuilder
- Inherited Members
Constructors
KafkaSchemaRegistryConfigurationBuilder()
public KafkaSchemaRegistryConfigurationBuilder()
Methods
Build()
Builds the KafkaSchemaRegistryConfiguration instance.
public KafkaSchemaRegistryConfiguration Build()
Returns
Exceptions
- BrokerConfigurationException
The configuration is not valid.
DisableSslCertificateVerification()
Disables the SSL certificate validation. This is insecure and should only be done in contained test or development environments.
public KafkaSchemaRegistryConfigurationBuilder DisableSslCertificateVerification()
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
EnableSslCertificateVerification()
Enables the SSL certificate validation.
public KafkaSchemaRegistryConfigurationBuilder EnableSslCertificateVerification()
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithBasicAuthCredentialsSource(AuthCredentialsSource?)
Sets the source of the basic authentication credentials. With Confluent.SchemaRegistry.AuthCredentialsSource.UserInfo
the credentials are specified in the BasicAuthUserInfo.
Confluent.SchemaRegistry.AuthCredentialsSource.SaslInherit requires the sasl.username and sasl.password
properties in the schema registry configuration, which are neither inherited from the producer or consumer configuration nor exposed
by the KafkaSchemaRegistryConfiguration.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithBasicAuthCredentialsSource(AuthCredentialsSource? basicAuthCredentialsSource)
Parameters
basicAuthCredentialsSourceAuthCredentialsSource?The source of the basic authentication credentials.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithBasicAuthUserInfo(string?)
Sets the basic authentication credentials in the form {username}:{password}.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithBasicAuthUserInfo(string? basicAuthUserInfo)
Parameters
basicAuthUserInfostringThe basic authentication credentials in the form {username}:{password}.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithBearerAuthClientId(string?)
Sets the client ID for the bearer authentication credentials.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithBearerAuthClientId(string? bearerAuthClientId)
Parameters
bearerAuthClientIdstringThe client ID for the bearer authentication credentials.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithBearerAuthClientSecret(string?)
Sets the client secret for the bearer authentication credentials.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithBearerAuthClientSecret(string? bearerAuthClientSecret)
Parameters
bearerAuthClientSecretstringThe client secret for the bearer authentication credentials.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithBearerAuthCredentialsSource(BearerAuthCredentialsSource?)
Sets the source of the bearer authentication credentials: a static token (see WithBearerAuthToken(string?)), an OAuth client (see WithBearerAuthClientId(string?) and WithBearerAuthClientSecret(string?)), the Azure Instance Metadata Service (IMDS) or a custom Confluent.SchemaRegistry.IAuthenticationHeaderValueProvider implementation.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithBearerAuthCredentialsSource(BearerAuthCredentialsSource? bearerAuthCredentialsSource)
Parameters
bearerAuthCredentialsSourceBearerAuthCredentialsSource?The source of the bearer authentication credentials.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithBearerAuthIdentityPoolId(string?)
Sets the identity pool for the bearer authentication credentials.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithBearerAuthIdentityPoolId(string? bearerAuthIdentityPoolId)
Parameters
bearerAuthIdentityPoolIdstringThe identity pool for the bearer authentication credentials.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithBearerAuthLogicalCluster(string?)
Sets the logical cluster for the bearer authentication credentials.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithBearerAuthLogicalCluster(string? bearerAuthLogicalCluster)
Parameters
bearerAuthLogicalClusterstringThe logical cluster for the bearer authentication credentials.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithBearerAuthScope(string?)
Sets the scope for the bearer authentication credentials.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithBearerAuthScope(string? bearerAuthScope)
Parameters
bearerAuthScopestringThe scope for the bearer authentication credentials.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithBearerAuthToken(string?)
Sets the bearer authentication token.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithBearerAuthToken(string? bearerAuthToken)
Parameters
bearerAuthTokenstringThe bearer authentication token.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithBearerAuthTokenEndpointQuery(string?)
Sets the token query parameters for the bearer token endpoint. Currently valid only when using the Azure Instance Metadata Service (IMDS) for token retrieval.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithBearerAuthTokenEndpointQuery(string? bearerAuthTokenEndpointQuery)
Parameters
bearerAuthTokenEndpointQuerystringThe token query parameters for the bearer token endpoint.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithBearerAuthTokenEndpointUrl(string?)
Sets the token endpoint for the bearer authentication credentials.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithBearerAuthTokenEndpointUrl(string? bearerAuthTokenEndpointUrl)
Parameters
bearerAuthTokenEndpointUrlstringThe token endpoint for the bearer authentication credentials.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithLatestCacheTtlSecs(int?)
Sets the TTL in seconds for caches holding latest schemas, or -1 for no TTL.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithLatestCacheTtlSecs(int? latestCacheTtlSecs)
Parameters
latestCacheTtlSecsint?The TTL in seconds for caches holding latest schemas, or -1 for no TTL.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithMaxCachedSchemas(int?)
Sets the maximum number of schemas that are cached by the schema registry client.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithMaxCachedSchemas(int? maxCachedSchemas)
Parameters
maxCachedSchemasint?The maximum number of schemas that are cached by the schema registry client.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithMaxConnectionsPerServer(int?)
Sets the maximum number of connections per server.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithMaxConnectionsPerServer(int? maxConnectionsPerServer)
Parameters
maxConnectionsPerServerint?The maximum number of connections per server.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithMaxRetries(int?)
Sets the maximum number of retries for a request.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithMaxRetries(int? maxRetries)
Parameters
maxRetriesint?The maximum number of retries for a request.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithRequestTimeoutMs(int?)
Sets the timeout in milliseconds for the requests to the Confluent schema registry.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithRequestTimeoutMs(int? requestTimeoutMs)
Parameters
requestTimeoutMsint?The timeout in milliseconds for the requests to the Confluent schema registry.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithRetriesMaxWaitMs(int?)
Sets the time to wait for any retry in milliseconds.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithRetriesMaxWaitMs(int? retriesMaxWaitMs)
Parameters
retriesMaxWaitMsint?The time to wait for any retry in milliseconds.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithRetriesWaitMs(int?)
Sets the time to wait for the first retry in milliseconds.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithRetriesWaitMs(int? retriesWaitMs)
Parameters
retriesWaitMsint?The time to wait for the first retry in milliseconds.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithSslCaLocation(string?)
Sets the file or directory path to the CA certificate(s) for verifying the registry's key.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithSslCaLocation(string? sslCaLocation)
Parameters
sslCaLocationstringThe file or directory path to the CA certificate(s) for verifying the registry's key.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithSslKeystoreLocation(string?)
Sets the path to the client's keystore (PKCS#12) used for the authentication.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithSslKeystoreLocation(string? sslKeystoreLocation)
Parameters
sslKeystoreLocationstringThe path to the client's keystore (PKCS#12) used for the authentication.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithSslKeystorePassword(string?)
Sets the client's keystore (PKCS#12) password.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithSslKeystorePassword(string? sslKeystorePassword)
Parameters
sslKeystorePasswordstringThe client's keystore (PKCS#12) password.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.
WithUrl(string?)
Sets the comma-separated list of URLs for schema registry instances that are used to register or lookup schemas.
[ExcludeFromCodeCoverage(Justification = "Generated code")]
public KafkaSchemaRegistryConfigurationBuilder WithUrl(string? url)
Parameters
urlstringThe comma-separated list of URLs for schema registry instances.
Returns
- KafkaSchemaRegistryConfigurationBuilder
The KafkaSchemaRegistryConfigurationBuilder so that additional calls can be chained.