Skip to content

feat: pubsub is publish-only — document intent or add a subscriber interface #202

@Lutherwaves

Description

@Lutherwaves

Check Existing Issues

  • I have searched the existing issues and discussions.

Problem Description

The pubsub package is publish-only. It ships an SNS publisher (pubsub/sns.go, pubsub/publisher.go) and telemetry wrapping, but there is no subscriber/consumer side. A service that needs to receive messages (SQS/SNS subscription, etc.) can't use pubsub for the inbound half, which is surprising for a building-blocks library whose stated goal is to keep messaging out of each microservice.

It's unclear whether this is intentional scoping or just not-yet-built, and the README's pubsub section doesn't say either way.

Desired Solution you'd like

Either:

  • Document that pubsub is intentionally publish-only (note it in the README pubsub section and the package doc), so users know to handle consumption themselves; or
  • Add a subscriber/consumer interface mirroring the publisher factory pattern (e.g. an SQS consumer), with the same telemetry wrapping.

A short decision in this issue is enough to unblock; happy to follow up with a PR for whichever direction.

Additional Context

Found during a general audit of the library. Filed as a question/enhancement because the right answer is a maintainer scoping call, not a bug fix.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestquestionFurther information is requested

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions