aggregated-state/

directory
v0.0.0-...-090737f Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 20, 2017 License: MIT

README

aggregated-state

Two producers to separate streams at different rates and a consumer that subscribes and aggregates information from both streams and prints out the current state.

Usage

Start the consumer.

go run consumer/main.go \
  -addr nats://localhost:4222 \
  -cluster test-cluster \
  -client eda-aggregated-state-consumer \
  -stream test-events \
  -stream2 visit-events

Start the first producer of test events.

go run producer-test-events/main.go \
  -addr nats://localhost:4222 \
  -cluster test-cluster \
  -client eda-aggregated-state-producer-test-events \
  -stream test-events \

Start the second producer of visit events.

go run producer-visit-events/main.go \
  -addr nats://localhost:4222 \
  -cluster test-cluster \
  -client eda-aggregated-state-producer-visit-events \
  -stream visit-events \

Note these are the default values, so go run main.go is sufficient.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL