Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update ndjson links due to domain expiry/resale #24306

Merged
merged 1 commit into from
Oct 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion command/agent/event_endpoint.go
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ func (s *HTTPServer) EventStream(resp http.ResponseWriter, req *http.Request) (i
if _, err := io.Copy(output, bytes.NewReader(res.Event.Data)); err != nil {
return CodedError(500, err.Error())
}
// Each entry is its own new line according to ndjson.org
// Each entry is its own new line according to https://github.com/ndjson/ndjson-spec
// append new line to each entry
fmt.Fprint(output, "\n")
}
Expand Down
8 changes: 4 additions & 4 deletions website/content/api-docs/events.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ The `/event/stream` endpoint is used to stream events generated by Nomad.

This endpoint streams a server's backlog of events as well as new events as they occur.
The stream will be kept alive until the connection is closed. The format of the response
body will be valid [ndjson](http://ndjson.org/). This means splitting the streaming
response at every `\n` character will guarantee each message is a valid JSON object.
Note that each JSON object may include multiple events (high server activity) or no
events (heartbeating to keep the connection open).
body will be valid [ndjson](https://github.com/ndjson/ndjson-spec). This means splitting
the streaming response at every `\n` character will guarantee each message is a valid
JSON object. Note that each JSON object may include multiple events (high server
activity) or no events (heartbeating to keep the connection open).

| Method | Path | Produces |
| ------ | ------------------ | ------------------ |
Expand Down