go-sdk/examples/streamsub
Josh van Leeuwen 9bc7d823cc
Update streaming subscription to understand new initial response (#601)
* Update streaming subscription to understand new initial response

Signed-off-by: joshvanl <me@joshvanl.dev>

* Update dapr CLI to 1.14.0-rc.6

Signed-off-by: joshvanl <me@joshvanl.dev>

* Update streamsub name in validate examples

Signed-off-by: joshvanl <me@joshvanl.dev>

* Apply suggestions from code review

Co-authored-by: Mike Nguyen <hey@mike.ee>
Signed-off-by: Josh van Leeuwen <me@joshvanl.dev>

---------

Signed-off-by: joshvanl <me@joshvanl.dev>
Signed-off-by: Josh van Leeuwen <me@joshvanl.dev>
Co-authored-by: Mike Nguyen <hey@mike.ee>
2024-07-23 13:53:33 -07:00
..
config Update streaming subscription to understand new initial response (#601) 2024-07-23 13:53:33 -07:00
pub Update streaming subscription to understand new initial response (#601) 2024-07-23 13:53:33 -07:00
sub Update streaming subscription to understand new initial response (#601) 2024-07-23 13:53:33 -07:00
README.md Update streaming subscription to understand new initial response (#601) 2024-07-23 13:53:33 -07:00

README.md

Dapr PubSub Example with go-sdk

This folder contains two Go files that use the Go SDK to invoke the Dapr Pub/Sub API.

Diagram

Step

Prepare

  • Dapr installed

Run Subscriber Server

dapr run --app-id sub \
         --dapr-http-port 3500 \
         --log-level debug \
         --resources-path ./config \
         go run sub/sub.go

Run Publisher

dapr run --app-id pub \
         --log-level debug \
         --resources-path ./config \
         go run pub/pub.go

Result

== APP == 2023/03/29 21:36:07 event - PubsubName: messages, Topic: neworder, ID: 82427280-1c18-4fab-b901-c7e68d295d31, Data: ping123