Commit Graph

453 Commits

Author SHA1 Message Date
Łukasz Magiera
1ac87279d7 Add --to-code to chain encode params 2021-08-20 18:13:05 +02:00
Łukasz Magiera
12875a9664 api/command for encoding actor params 2021-08-20 17:32:57 +02:00
Aarsh Shah
d7076778e2
integrate DAG store and CARv2 in deal-making (#6671)
This commit removes badger from the deal-making processes, and
moves to a new architecture with the dagstore as the cental
component on the miner-side, and CARv2s on the client-side.

Every deal that has been handed off to the sealing subsystem becomes
a shard in the dagstore. Shards are mounted via the LotusMount, which
teaches the dagstore how to load the related piece when serving
retrievals.

When the miner starts the Lotus for the first time with this patch,
we will perform a one-time migration of all active deals into the
dagstore. This is a lightweight process, and it consists simply
of registering the shards in the dagstore.

Shards are backed by the unsealed copy of the piece. This is currently
a CARv1. However, the dagstore keeps CARv2 indices for all pieces, so
when it's time to acquire a shard to serve a retrieval, the unsealed
CARv1 is joined with its index (safeguarded by the dagstore), to form
a read-only blockstore, thus taking the place of the monolithic
badger.

Data transfers have been adjusted to interface directly with CARv2 files.
On inbound transfers (client retrievals, miner storage deals), we stream
the received data into a CARv2 ReadWrite blockstore. On outbound transfers
(client storage deals, miner retrievals), we serve the data off a CARv2
ReadOnly blockstore.

Client-side imports are managed by the refactored *imports.Manager
component (when not using IPFS integration). Just like it before, we use
the go-filestore library to avoid duplicating the data from the original
file in the resulting UnixFS DAG (concretely the leaves). However, the
target of those imports are what we call "ref-CARv2s": CARv2 files placed
under the `$LOTUS_PATH/imports` directory, containing the intermediate
nodes in full, and the leaves as positional references to the original file
on disk.

Client-side retrievals are placed into CARv2 files in the location:
`$LOTUS_PATH/retrievals`.

A new set of `Dagstore*` JSON-RPC operations and `lotus-miner dagstore`
subcommands have been introduced on the miner-side to inspect and manage
the dagstore.

Despite moving to a CARv2-backed system, the IPFS integration has been
respected, and it continues to be possible to make storage deals with data
held in an IPFS node, and to perform retrievals directly into an IPFS node.

NOTE: because the "staging" and "client" Badger blockstores are no longer
used, existing imports on the client will be rendered useless. On startup,
Lotus will enumerate all imports and print WARN statements on the log for
each import that needs to be reimported. These log lines contain these
messages:

- import lacks carv2 path; import will not work; please reimport
- import has missing/broken carv2; please reimport

At the end, we will print a "sanity check completed" message indicating
the count of imports found, and how many were deemed broken.

Co-authored-by: Aarsh Shah <aarshkshah1992@gmail.com>
Co-authored-by: Dirk McCormick <dirkmdev@gmail.com>

Co-authored-by: Raúl Kripalani <raul@protocol.ai>
Co-authored-by: Dirk McCormick <dirkmdev@gmail.com>
2021-08-16 23:34:32 +01:00
ZenGround0
2e5b492edd
Merge pull request #6097 from filcloud/sectors-renew
Extending sectors: more practical and flexible tools
2021-08-16 13:50:38 -04:00
He Weidong
92402e9f23 Update doc 2021-08-16 21:31:21 +08:00
ZenGround0
bfda864c1b Fix docsgen 2021-08-11 09:49:23 -04:00
ZenGround0
b914e95f34 revert pricelist by version to pricelist by epoch 2021-08-11 09:49:23 -04:00
Steven Allen
57bf5c2143 feat: add ChainGetTipSetAfterHeight
This is identical to ChainGetTipSetByHeight, but returns the tipset
following any null tipsets. This is what the user usually wants anyways.

(and I need it for another PR)
2021-08-05 12:07:14 -07:00
Raúl Kripalani
8433aae1af use fallback api infos last; init service with markets-path. 2021-07-29 16:10:04 +01:00
Raúl Kripalani
90427bc3af fix docs, add flag. 2021-07-29 13:39:03 +01:00
ZenGround0
11394aa4aa Improve cli docs 2021-07-29 00:29:27 -04:00
ZenGround0
8ccee51887 docsgen 2021-07-29 00:24:24 -04:00
Raúl Kripalani
07f40b9488 fix docs and nits. 2021-07-28 20:03:25 +01:00
Anton Evangelatov
de4a847078 add RuntimeSubsystems API method; use it in lotus-miner info 2021-07-28 16:02:05 +03:00
Jennifer Wang
f9595b58ee make gen 2021-07-27 23:02:54 -04:00
Raúl Kripalani
b04fb75a92 rename flag to very verbose. 2021-07-27 20:49:30 +01:00
Raúl Kripalani
3451acbc03 docgen. 2021-07-27 15:28:10 +01:00
vyzo
1f6935f8c4 make gen 2021-07-26 12:15:01 +03:00
vyzo
77604db716 make gen 2021-07-26 08:33:25 +03:00
vyzo
21bb2bda09 make gen 2021-07-25 11:25:29 +03:00
Łukasz Magiera
4b8a5068bd cli docsgen 2021-07-23 15:44:52 +02:00
Łukasz Magiera
97f5bb66c7 config: doc struct codegen 2021-07-23 13:55:50 +02:00
Łukasz Magiera
f9752d8a0a
Merge branch 'master' into feat/compact-sectors-numbers-cmd 2021-07-22 19:00:33 +02:00
Łukasz Magiera
15a6995cda fix lint 2021-07-22 16:31:04 +02:00
ZenGround0
09adc4d5e2 make docsgen changes 2021-07-22 09:49:47 -04:00
ZenGround0
cbc07cb939 Add 6.5 to VersionForNetwork commit updated docs 2021-07-22 09:49:47 -04:00
hunjixin
bdaa73a413 add ChainGetMessagesInTipset api 2021-07-15 14:52:09 +08:00
Łukasz Magiera
dd09666399
Merge pull request #6743 from filecoin-project/chore/centralize_all_cli_color_handling
Handle the --color flag via proper global state
2021-07-13 17:34:25 +02:00
Anton Evangelatov
2af02af1c1 rename --name to --type; provide empty stores.StorageConfig when init new service 2021-07-13 12:57:43 +02:00
Peter Rabbitson
6efd2e7335 Handle the --color flag via proper global state
Use `color.NoColor` as a global progressively modified as one descends
down command flags. Allows non-surprising operation when --color is
accepted at multiple layers, and even makes this behave predictably:

    lotus-miner --color actor control list --color=false
2021-07-13 12:22:29 +02:00
Anton Evangelatov
7728d6bfc3 remove --enable-markets flag; add --name string slice flag 2021-07-12 14:38:29 +02:00
Anton Evangelatov
d89ddb9315 resolve conflicts 2021-07-12 11:34:37 +02:00
Aayush Rajasekaran
13dcfec8fe Release template: Update all testnet infra at once 2021-07-11 17:26:21 -04:00
Łukasz Magiera
8f7bf1df86
Merge pull request #6697 from filecoin-project/feat/dealpublish-ctl-config
Config for deal publishing control addresses
2021-07-08 19:00:29 +02:00
Peter Rabbitson
140a2e0200 Stabilize default text and make gen docsgen-cli 2021-07-08 10:44:13 +02:00
Łukasz Magiera
2dc27d6ab4 itests: Fix deal provider collateral flakiness 2021-07-07 19:41:46 +02:00
Jim Pick
a8ca7baa93 Run make docsgen-cli 2021-07-06 18:16:06 +00:00
Anton Evangelatov
ff2772a58c resolved conflicts 2021-07-06 16:00:41 +02:00
Aayush Rajasekaran
069fd0a244 Add helptext to lotus chain export 2021-07-03 12:41:43 -04:00
Anton Evangelatov
e9d0a25436 remove redundant flag from docs 2021-07-02 15:11:57 +02:00
Anton Evangelatov
287e06995a missing flag, that will need to be refactored 2021-07-02 12:41:28 +02:00
Anton Evangelatov
4f0a96c9c7 resolved conflicts 2021-06-30 13:16:52 +02:00
Łukasz Magiera
df86efbd43 docsgen 2021-06-29 11:27:06 +02:00
Aayush Rajasekaran
4af59e0188
Apply suggestions from code review
Co-authored-by: Jennifer <42981373+jennijuju@users.noreply.github.com>
2021-06-22 19:23:24 -04:00
Aayush Rajasekaran
07fad6a201 Fix helptext 2021-06-22 16:02:06 -04:00
Anton Evangelatov
6720463799 resolve merge conflicts 2021-06-22 11:28:23 +02:00
Raúl Kripalani
c0a8a9f5b5 make gen. 2021-06-21 20:52:59 +01:00
Łukasz Magiera
44de67cf7d
Merge pull request #6175 from filecoin-project/feat/dynamic-retreival-pricing
Dynamic Retrieval pricing
2021-06-17 10:25:48 +02:00
Anton Evangelatov
d45bb14015 Merge branch 'master' into nonsense/split-market-miner-processes 2021-06-16 18:49:15 +02:00
Aayush Rajasekaran
bee548face Add utils to use multisigs as miner owners 2021-06-15 16:57:52 -04:00