RedisResource Properties

ClassProperties8 members
A resource that represents a Redis resource independent of the hosting model.
ConnectionStringExpressionSection titled ConnectionStringExpressionReferenceExpression
Gets the connection string expression for the Redis server.
public ReferenceExpression ConnectionStringExpression { get; }
HostSection titled HostEndpointReferenceExpression
Gets the host endpoint reference for this resource.
public EndpointReferenceExpression Host { get; }
PasswordParameterSection titled PasswordParameternullableParameterResource?
Gets the parameter that contains the Redis server password.
public ParameterResource? PasswordParameter { get; }
PortSection titled PortEndpointReferenceExpression
Gets the port endpoint reference for this resource.
public EndpointReferenceExpression Port { get; }
PrimaryEndpointSection titled PrimaryEndpointEndpointReference
Gets the primary endpoint for the Redis server.
public EndpointReference PrimaryEndpoint { get; }
ResourceTypeDisplayNameSection titled ResourceTypeDisplayNameoverridestring
Gets the default human-readable name of this resource's type.
public override string ResourceTypeDisplayName { get; }
Override this property to identify the service, such as Redis or PostgreSQL Server, independently of its technical resource type. The default is the resource type. This label does not change the resource name, service discovery, or OpenTelemetry identity. Use ResourceBuilderExtensions.WithResourceTypeDisplayName to override the label for an instance.
Indicates whether TLS is enabled for the Redis server.
public bool TlsEnabled { get; }
This property proxies through to EndpointAnnotation.TlsEnabled on the RedisResource.PrimaryEndpoint. When set to true, the connection string expression dynamically includes ,ssl=true and the URI expression uses the rediss:// scheme. This value is resolved lazily at expression evaluation time, avoiding timing issues when TLS is enabled later in the application lifecycle (e.g., during the BeforeStartEvent).
UriExpressionSection titled UriExpressionReferenceExpression
Gets the connection URI expression for the Redis server.
public ReferenceExpression UriExpression { get; }
Format: redis://[:{password}@]{host}:{port}. The password segment is omitted when no password is configured.