mirror of
https://github.com/ipfs/kubo.git
synced 2026-02-21 18:37:45 +08:00
doc: expand and cleanup badger documentation
This commit is contained in:
parent
f455c8bac2
commit
d600378094
@ -38,13 +38,13 @@ Uses a leveldb database to store key value pairs.
|
||||
## badgerds
|
||||
Uses [badger](https://github.com/dgraph-io/badger) as a key value store.
|
||||
|
||||
* `syncWrites`: Synchronize every write to disk.
|
||||
* `truncate`: Truncate the DB if a corrupted sector is found (otherwise Badger won't start). This option is always set to `true` in Windows if `syncWrites` is set.
|
||||
* `syncWrites`: Flush every write to disk before continuing. Disabling this option may leave your datastore in an inconsistent state after a crash.
|
||||
* `truncate`: Truncate the DB if a partially written sector is found (defaults to true). This only happens if a IPFS crashes half-way through a write so this option is usually safe to leave on.
|
||||
|
||||
```json
|
||||
{
|
||||
"type": "badgerds",
|
||||
"path": "<location of badger inside repo",
|
||||
"path": "<location of badger inside repo>",
|
||||
"syncWrites": true|false,
|
||||
"truncate": true|false,
|
||||
}
|
||||
|
||||
@ -507,27 +507,29 @@ See [Plugin docs](./plugins.md)
|
||||
- [ ] More plugins and plugin types
|
||||
- [ ] Feedback on stability
|
||||
|
||||
## Badger datastore
|
||||
## Badger datastore
|
||||
|
||||
### In Version
|
||||
0.4.11
|
||||
### In Version
|
||||
|
||||
Badger-ds is new datastore implementation based on
|
||||
https://github.com/dgraph-io/badger
|
||||
0.4.11
|
||||
|
||||
### Basic Usage
|
||||
Badger-ds is new datastore implementation based on
|
||||
https://github.com/dgraph-io/badger.
|
||||
|
||||
|
||||
```
|
||||
$ ipfs init --profile=badgerds
|
||||
```
|
||||
or install https://github.com/ipfs/ipfs-ds-convert/ and
|
||||
```
|
||||
[BACKUP ~/.ipfs]
|
||||
$ ipfs config profile apply badgerds
|
||||
$ ipfs-ds-convert convert
|
||||
```
|
||||
### Basic Usage
|
||||
|
||||
###
|
||||
```
|
||||
$ ipfs init --profile=badgerds
|
||||
```
|
||||
or install https://github.com/ipfs/ipfs-ds-convert/ and
|
||||
```
|
||||
[BACKUP ~/.ipfs]
|
||||
$ ipfs config profile apply badgerds
|
||||
$ ipfs-ds-convert convert
|
||||
```
|
||||
|
||||
You can read more in the [datastore](./datastores.md#badgerds) documentation.
|
||||
|
||||
### Road to being a real feature
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user