Skip to content

Commit

Permalink
Reader Operator HTTP API now accepts /v1/restart
Browse files Browse the repository at this point in the history
# Conflicts:
#	CHANGELOG.md
  • Loading branch information
maoueh committed Jan 15, 2025
1 parent f38a195 commit 9be23e0
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ If you were at `firehose-core` version `1.0.0` and are bumping to `1.1.0`, you s

## Unreleased

### Reader

* Reader Node Manager HTTP API now accepts `POST http://localhost:10011/v1/restart<?sync=true>` to restart the underlying reader node binary sub-process. This is a alias for `/v1/reload`.

### Tools

* Enhanced `firecore tools print merged-blocks` with various small quality of life improvements:
Expand All @@ -24,7 +28,7 @@ If you were at `firehose-core` version `1.0.0` and are bumping to `1.1.0`, you s
> This release will reject firehose connections from clients that don't support GZIP or ZSTD compression. Use `--firehose-enforce-compression=false` to keep previous behavior, then check the logs for `incoming Substreams Blocks request` logs with the value `compressed: false` to track users who are not using compressed HTTP connections.
> [!IMPORTANT]
> This release removes the old `sf.firehose.v1` protocol (replaced by `sf.firehose.v2` in 2022, this should not affect any reasonably recent client)
> This release removes the old `sf.firehose.v1` protocol (replaced by `sf.firehose.v2` in 2022, this should not affect any reasonably recent client).
* Add support for ConnectWeb firehose requests.
* Always use gzip compression on firehose requests for clients that support it (instead of always answering with the same compression as the request).
Expand Down
1 change: 1 addition & 0 deletions node-manager/operator/http_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ func (o *Operator) RunHTTPServer(httpListenAddr string, options ...HTTPOption) *
r.HandleFunc("/v1/restore", o.restoreHandler).Methods("POST")
r.HandleFunc("/v1/list_backups", o.listBackupsHandler).Methods("GET")
r.HandleFunc("/v1/reload", o.reloadHandler).Methods("POST")
r.HandleFunc("/v1/restart", o.reloadHandler).Methods("POST")
r.HandleFunc("/v1/safely_reload", o.safelyReloadHandler).Methods("POST")
r.HandleFunc("/v1/safely_pause_production", o.safelyPauseProdHandler).Methods("POST")
r.HandleFunc("/v1/safely_resume_production", o.safelyResumeProdHandler).Methods("POST")
Expand Down
2 changes: 1 addition & 1 deletion node-manager/operator/operator.go
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ func (o *Operator) runCommand(cmd *Command) error {
}
return nil

case "reload":
case "reload", "restart":
o.zlogger.Info("preparing for reload")
if err := o.cleanSuperviserStop(); err != nil {
return err
Expand Down

0 comments on commit 9be23e0

Please sign in to comment.