DivoPulsar

A library implementing the Divo Stack behaviour, providing a pre-configured Pulsar broker via docker-compose for integration testing Elixir apps. The broker runs in standalone mode.

Requires inclusion of the Divo library in your mix project.

Installation

The package can be installed by adding divo and divo_pulsar to your list of dependencies in mix.exs:

def deps do
[
{:divo, "~> 1.1.0"},
{:divo_pulsar, "~> 0.1.0"}
]
end

Use

In your Mix configuration file (i.e. config/integration.exs), include the following:

config :myapp,
divo: [
{DivoPulsar, [port: 8080]}
]

In your integration test, specify that you want to use Divo:

use Divo, services: [:pulsar]

The resulting stack will create a single Pulsar broker in standalone mode exposing the standard port 6650 for broker communication and port 8080 for the api.

Configuration

You may omit the configuration arguments to DivoPulsar and still have a working stack. The unmodified configuration will create the broker only and only expose the producer/consumer port.

See Divo GitHub or Divo Hex Documentation for more instructions on using and configuring the Divo library. See Pulsar Dockerhub for further documentation on using and configuring the features of the container image itself. See Pulsar source for the full codebase behind Pulsar