MCPcopy
hub / github.com/nats-io/nats.go / CreatePushConsumer

Method CreatePushConsumer

jetstream/stream.go:147–147  ·  view source on GitHub ↗

CreatePushConsumer creates a push consumer on a given stream with given config. If consumer already exists and the provided configuration differs from its configuration, ErrConsumerExists is returned. If the provided configuration is the same as the existing consumer, the existing consumer is return

(ctx context.Context, cfg ConsumerConfig)

Source from the content-addressed store, hash-verified

145 // existing consumer is returned. Consumer interface is returned,
146 // allowing to consume messages.
147 CreatePushConsumer(ctx context.Context, cfg ConsumerConfig) (PushConsumer, error)
148
149 // UpdatePushConsumer updates an existing push consumer. If consumer does not
150 // exist, ErrConsumerDoesNotExist is returned. Consumer interface is

Callers 8

TestConsumerInfoFunction · 0.65
TestPushConsumerConsumeFunction · 0.65
TestCreateConsumerFunction · 0.65
TestUpdateConsumerFunction · 0.65
TestConsumerPushVsPullFunction · 0.65

Implementers 1

streamjetstream/stream.go

Calls

no outgoing calls

Tested by 8

TestConsumerInfoFunction · 0.52
TestPushConsumerConsumeFunction · 0.52
TestCreateConsumerFunction · 0.52
TestUpdateConsumerFunction · 0.52
TestConsumerPushVsPullFunction · 0.52