MCPcopy Index your code
hub / github.com/riverqueue/river / emitQueueNotification

Function emitQueueNotification

producer_test.go:816–836  ·  view source on GitHub ↗
(t *testing.T, ctx context.Context, exec riverdriver.Executor, schema, queue, action string, metadata []byte)

Source from the content-addressed store, hash-verified

814}
815
816func emitQueueNotification(t *testing.T, ctx context.Context, exec riverdriver.Executor, schema, queue, action string, metadata []byte) {
817 t.Helper()
818
819 payload := map[string]any{
820 "queue": queue,
821 "action": action,
822 }
823 if metadata != nil {
824 payload["metadata"] = metadata
825 }
826
827 payloadBytes, err := json.Marshal(payload)
828 require.NoError(t, err)
829
830 err = exec.NotifyMany(ctx, &riverdriver.NotifyManyParams{
831 Topic: string(notifier.NotificationTopicControl),
832 Payload: []string{string(payloadBytes)},
833 Schema: schema,
834 })
835 require.NoError(t, err)
836}

Callers 1

testProducerFunction · 0.85

Calls 2

HelperMethod · 0.65
NotifyManyMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…