Skip to content

Commit

Permalink
tweak comments
Browse files Browse the repository at this point in the history
  • Loading branch information
walterra committed May 22, 2024
1 parent 222222f commit c15ee16
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions examples/response_stream/server/routes/reducer_stream.ts
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,8 @@ export const defineReducerStreamRoute = (router: IRouter, logger: Logger) => {
// Throw an error. It should not crash Kibana!
// It should be caught and logged to the Kibana server console.
// The stream will just stop but the client will note receive an error!
// In practice this pattern should be avoided as it will just end
// the stream without an explanation.
throw new Error('There was a (simulated) server side error!');

case 'emit-error':
Expand Down
2 changes: 2 additions & 0 deletions examples/response_stream/server/routes/redux_stream.ts
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,8 @@ export const defineReduxStreamRoute = (router: IRouter, logger: Logger) => {
// Throw an error. It should not crash Kibana!
// It should be caught and logged to the Kibana server console.
// The stream will just stop but the client will note receive an error!
// In practice this pattern should be avoided as it will just end
// the stream without an explanation.
throw new Error('There was a (simulated) server side error!');

case 'emit-error':
Expand Down

0 comments on commit c15ee16

Please sign in to comment.