mirror of
https://github.com/hoytech/strfry.git
synced 2025-06-21 18:15:24 +00:00
DB upgrade instructions
This commit is contained in:
13
README.md
13
README.md
@ -60,6 +60,19 @@ The `strfry export` command will print events from the DB to standard output in
|
|||||||
Optionally, you can limit the time period exported with the `--since` and `--until` flags.
|
Optionally, you can limit the time period exported with the `--since` and `--until` flags.
|
||||||
|
|
||||||
|
|
||||||
|
### DB Upgrade
|
||||||
|
|
||||||
|
In the past, incompatible changes have been made to the DB format. If you try to use a `strfry` binary with an incompatible DB version, an error will be thrown. Only the `strfry export` command will work.
|
||||||
|
|
||||||
|
In order to upgrade the DB, you should export and then import again:
|
||||||
|
|
||||||
|
./strfry export > dbdump.jsonl
|
||||||
|
mv strfry-db/data.mdb data.mdb.bak
|
||||||
|
./strfry import < dbdump.jsonl
|
||||||
|
|
||||||
|
After you have confirmed everything is working OK, the `dbdump.jsonl` and `data.mdb.bak` files can be deleted.
|
||||||
|
|
||||||
|
|
||||||
### Stream
|
### Stream
|
||||||
|
|
||||||
This command opens a websocket connection to the specified relay and makes a nostr `REQ` request with filter `{"limit":0}`:
|
This command opens a websocket connection to the specified relay and makes a nostr `REQ` request with filter `{"limit":0}`:
|
||||||
|
Reference in New Issue
Block a user