跳转到内容
DocsTry Aspire
DocsTry

Get started with LavinMQ and Aspire

此内容尚不支持你的语言。

⭐ Community Toolkit LavinMQ logo

LavinMQ is a message broker that implements AMQP 0-9-1 and is wire-compatible with RabbitMQ. The Aspire hosting integration runs LavinMQ as a container and exposes its AMQP connection properties to consuming apps.

  • Container orchestration. Aspire runs docker.io/cloudamqp/lavinmq with AMQP and management endpoints.
  • Connection-property injection. Referencing the resource provides the host, port, credentials, and AMQP URI to an app.
  • Persistent storage options. Store broker data in a named volume or a host bind mount.
  • Built-in health checks. The hosting integration checks the broker through a RabbitMQ-compatible connection.
  • Multi-language clients. C#, TypeScript, Python, and Go can use established RabbitMQ-compatible AMQP 0-9-1 libraries.

LavinMQ has no dedicated Community Toolkit client package. Use the Aspire RabbitMQ client integration for C# or a RabbitMQ-compatible client for your language.

architecture-beta

  group apphost(server)[AppHost]
  group consumer(server)[Consuming app]

  service hosting(server)[Hosting integration] in apphost
  service lavinmq(server)[LavinMQ broker] in apphost
  service client(iconoir:server-connection)[AMQP client] in consumer
  service app(server)[Application] in consumer

  hosting:R --> L:lavinmq
  lavinmq:R --> L:client
  client:R --> L:app
  1. Install the hosting integration, add the broker resource, and configure ports or persistent storage.

    Set up LavinMQ

  2. Reference the broker from an app and use the injected AMQP URI with a RabbitMQ-compatible client.

    Connect to LavinMQ