confluentinc / confluentinc/vscode

Add CodeLens option to Dataset files for creating Medusa Server-Sent Events Streams

Open
#2,321 0 comments 0 reactions 0 assignees View on GitHub
data generation
Dominant language
TypeScript
Stars
34
Forks
17
Avg merge
1d 22h
Merged PRs (30d)
8

Description

_Note_: A Dataset may include multiple Events, each optionally mapped to a specific topic. Events can share a topic, use separate ones, or be left unmapped. A Medusa SSE stream therefore can contain SSE events from multiple Medusa 'Events'.

Below flow shows the process of creating a stream from a *.dataset.json.

Image

Image

On click of the Produce Stream option is when the stream will be created. For this the Medusa build stream endpoints can be used:
`POST /v1/streams/{streamId}`
`POST /v1/streams`

These endpoints take the Dataset content as the POST body. And each will return a StreamDetails response:

```
{
"stream_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"tag": "string",
"started": true,
"subscriptions": 0
}
```

These endpoints accept an optional 'tag' query parameter, this should be sent to improve the UX so the user can easily identify any running streams as opposed to displaying the Stream IDs in the UI. The Dataset file name could be a good option for this.

_Note_: This ticket does not include the subscription to these SSE streams or production to Kafka, it is focused only on Stream creation.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.