Skip to content

feat(testing): implement ResetConsumer methods on SyncJetStream - #27

Merged
josemarluedke merged 1 commit into
mainfrom
feat/jetstream-reset-consumer
May 8, 2026
Merged

feat(testing): implement ResetConsumer methods on SyncJetStream#27
josemarluedke merged 1 commit into
mainfrom
feat/jetstream-reset-consumer

Conversation

@josemarluedke

@josemarluedke josemarluedke commented May 8, 2026

Copy link
Copy Markdown
Member

Summary

  • Add ResetConsumer and ResetConsumerToSequence stubs to SyncJetStream so it satisfies the updated jetstream.JetStream interface.
  • Bump nats.go direct dep to v1.52.0 (the version that introduced the new interface methods).

Why

nats.go v1.52.0 grew the jetstream.JetStream interface with two new methods. Without these stubs var _ jetstream.JetStream = (*SyncJetStream)(nil) fails to compile in any project that pulls in nats.go v1.52+ alongside go-outbox/testing — for example, iam-api hit this in CI when its messagebus bump transitively required nats.go v1.52.

The new methods follow the same return "not implemented" shape as the existing unused stubs (Consumer, DeleteConsumer, AccountInfo, etc.), since the synchronous test harness has no concept of consumer reset.

Test plan

  • go build ./... clean
  • go test ./testing/... passes
  • Downstream verification: iam-api CI passes once it bumps to the next go-outbox release

nats.go v1.52.0 added ResetConsumer and ResetConsumerToSequence to
the jetstream.JetStream interface. Without stubs SyncJetStream no
longer satisfies the interface, breaking any consumer that pulls in
both nats.go v1.52+ and go-outbox/testing (e.g. iam-api).

Both stubs return "not implemented", matching the rest of the
unused-method stubs in this file. Bump nats.go to v1.52.0 to pick up
the interface change so the build assertion stays accurate.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@josemarluedke josemarluedke added the Type: Internal Internal changes in dependencies/tests or project maintenance label May 8, 2026
@josemarluedke
josemarluedke merged commit bda235f into main May 8, 2026
1 of 2 checks passed
@josemarluedke
josemarluedke deleted the feat/jetstream-reset-consumer branch May 8, 2026 18:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Type: Internal Internal changes in dependencies/tests or project maintenance

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant