RedPandaBuilderExtensions
Classstaticnet10.0
Provides extension methods for adding Redpanda resources to an
Hosting.IDistributedApplicationBuilder. namespace Aspire.Hosting;
public static class RedPandaBuilderExtensions{ // ...}8 members
Methods8
Section titled MethodsAddRedPanda(IDistributedApplicationBuilder, string, int?)extensionats exportIResourceBuilder<RedPandaServerResource> Adds a Redpanda container resource to the application. Redpanda is a Kafka API compatible streaming platform, so the resource can be referenced by any Kafka client integration.
AddRedPanda(IDistributedApplicationBuilder, string, Action<RedPandaServerOptions>, int?)extensionats ignoredIResourceBuilder<RedPandaServerResource> Adds a Redpanda container resource to the application, using a delegate to configure broker options such as the CPU and memory limits. Redpanda is a Kafka API compatible streaming platform, so the resource can be referenced by any Kafka client integration.
WithConsole(IResourceBuilder<RedPandaServerResource>, Action<IResourceBuilder<RedPandaConsoleContainerResource>>, string?)extensionats exportIResourceBuilder<RedPandaServerResource> Adds a Redpanda Console container to the application, configured to connect to the Redpanda broker.
WithDataBindMount(IResourceBuilder<RedPandaServerResource>, string, bool)extensionats exportIResourceBuilder<RedPandaServerResource> Adds a bind mount for the data folder to a Redpanda container resource.
WithDataVolume(IResourceBuilder<RedPandaServerResource>, string?, bool)extensionats exportIResourceBuilder<RedPandaServerResource> Adds a named volume for the data folder to a Redpanda container resource.
WithHostPort(IResourceBuilder<RedPandaConsoleContainerResource>, int?)extensionats exportIResourceBuilder<RedPandaConsoleContainerResource> Configures the host port that the Redpanda Console resource is exposed on instead of using a randomly assigned port.
WithHostPort(IResourceBuilder<RedPandaKafkaUiContainerResource>, int?)extensionats ignoredIResourceBuilder<RedPandaKafkaUiContainerResource> Configures the host port that the Kafka UI resource is exposed on instead of using a randomly assigned port.
WithKafkaUI(IResourceBuilder<RedPandaServerResource>, Action<IResourceBuilder<RedPandaKafkaUiContainerResource>>, string?)extensionats exportIResourceBuilder<RedPandaServerResource> Adds a Kafka UI container to the application, configured to connect to the Redpanda broker. This is the same Kafka management UI (the
kafbat/kafka-ui image) used by the official Aspire Kafka integration, so it works against any Kafka API compatible broker.