README

commandbus GoDoc

Package commandbus provides command bus interfaces

Download:

go get -u github.com/vardius/go-api-boilerplate/pkg/commandbus

Package commandbus provides command bus interfaces

Expand ▾ Collapse ▴

Documentation

Overview

    Package commandbus provides interfaces along with helper functions

    Index

    Constants

    This section is empty.

    Variables

    This section is empty.

    Functions

    This section is empty.

    Types

    type CommandBus

    type CommandBus interface {
    	Publish(ctx context.Context, command domain.Command, out chan<- error)
    	Subscribe(ctx context.Context, commandName string, fn CommandHandler) error
    	Unsubscribe(ctx context.Context, commandName string, fn CommandHandler) error
    }

      CommandBus allows to subscribe/dispatch commands

      type CommandHandler

      type CommandHandler interface{}

        CommandHandler function

        Directories

        Path Synopsis