Commit Graph

2286 Commits

Author SHA1 Message Date
Mak Muftic
3433fa4a6e Add stringdocs to config props and generate docs 2021-09-29 12:51:43 +02:00
Mak Muftic
36913f4efc Fix elasticsearch index setup 2021-09-27 13:28:28 +02:00
Matija Petrunic
6c680e306d Rename json tracer flag 2021-09-24 16:25:41 +02:00
Mak Muftic
30fc2387be Merge branch 'mpetrun5/lotus-extended-tracer' of github.com:ChainSafe/lotus into mpetrun5/lotus-extended-tracer 2021-09-24 14:16:31 +02:00
Mak Muftic
9332b9f399 Change json config naming 2021-09-24 13:53:31 +02:00
Mak Muftic
4438c4bd87 Move index name to config only and add default value 2021-09-24 13:43:25 +02:00
Mak Muftic
22bbb113e7 Fix schema creation 2021-09-24 12:58:32 +02:00
Mak Muftic
94a1601ab2 Remove hardcoded url schema 2021-09-24 12:40:33 +02:00
Mak Muftic
e46da5a181 Add cli flags 2021-09-24 12:37:16 +02:00
Matija Petrunic
0c390d12f7 Append source auth flag to lotus tracer event 2021-09-21 12:54:07 +02:00
Matija Petrunic
d65d9aa6e0 Send peerID peer score as separate events to enable usage of kibana runtime fields 2021-09-21 12:30:50 +02:00
Mak Muftic
082f70757c Revert additional logging in elastic client 2021-09-20 12:29:12 +02:00
Mak Muftic
a685ccc955 Remove document id 2021-09-17 15:14:39 +02:00
Mak Muftic
0962e73e3e Add loger to elastic search client 2021-09-17 14:22:57 +02:00
Matija Petrunic
7d0aefacbb Change peer score event type to avoid exceeding elastisearch field limit 2021-09-17 13:46:26 +02:00
Matija Petrunic
a91ffa60d6 Set peer id event as string in lotus trace event 2021-09-17 12:11:14 +02:00
Mak Muftic
dc79ea363d Change index name 2021-09-17 11:35:36 +02:00
Mak Muftic
f09f5c2d11 Change elastic document name 2021-09-16 16:49:47 +02:00
Mak Muftic
8e2b474fc7 Use only one document on elastic 2021-09-16 16:44:35 +02:00
Matija Petrunic
9efa495b0e Write every trace to new line when using json transport 2021-09-16 16:42:18 +02:00
Matija Petrunic
941a0f7153 Update peer score tracker creation to include lotus tracer 2021-09-16 16:31:36 +02:00
Matija Petrunic
9cdc5261c4 Fix lotus tracer being nil when remote tracer is not configured 2021-09-16 15:53:39 +02:00
Matija Petrunic
d067bc9f01 Move creating and opening file to json transport constructor 2021-09-16 15:22:18 +02:00
Matija Petrunic
e2206147cc Add source auth token to lotus traces 2021-09-16 12:21:57 +02:00
Mak Muftic
c25a5e06cf Use config string for elasticsearch client 2021-09-16 12:15:42 +02:00
Mak Muftic
5cbd2519da Remove processing elasticsearch result 2021-09-15 16:20:36 +02:00
Mak Muftic
67c1d633c6 Rename jsonEvent to evt 2021-09-15 16:16:12 +02:00
Mak Muftic
add13c2646 Code cleanup 2021-09-15 16:05:44 +02:00
Mak Muftic
71a2ca9e7c Add new wrapper structure in tracer transport 2021-09-15 16:03:51 +02:00
Mak Muftic
707faf57b5 Code cleanup 2021-09-15 15:11:34 +02:00
Mak Muftic
e20cd0ef27 Propagate error on creating transport 2021-09-15 14:58:36 +02:00
Mak Muftic
cf06096565 Fix tracer initialization 2021-09-15 14:54:20 +02:00
Mak Muftic
bb85ca031d Add elasticsearch transport 2021-09-15 14:50:27 +02:00
Matija Petrunic
c064ce4852 Add generated documentation 2021-09-15 14:22:48 +02:00
Matija Petrunic
8a657b90a7 Refactor lotus tracer to behave like lp2p tracer 2021-09-15 13:41:56 +02:00
Matija Petrunic
ab86c5419d Implement json tracer transport 2021-09-15 13:41:03 +02:00
Matija Petrunic
8e6a01de6d Add configuration in pubsub to trace locally to json file 2021-09-15 13:40:54 +02:00
Matija Petrunic
d5a4b0637a Add lotus tracer transport calls 2021-09-10 15:37:38 +02:00
Mak Muftic
c367533a3c Add transport interface 2021-09-10 12:36:38 +02:00
Matija Petrunic
b1dafd81b8 Add peer score tracing on pubsub peer score inspect 2021-08-30 14:49:10 +02:00
Matija Petrunic
99fbd7039e Update pubsub tracking to trace from lotus and lp2p tracers 2021-08-30 14:38:15 +02:00
Matija Petrunic
522858c871 Add lotus tracer interface 2021-08-30 14:35:15 +02:00
Aarsh Shah
e1a056db46 ignore nil throttler 2021-08-24 10:42:00 +05:30
Łukasz Magiera
12875a9664 api/command for encoding actor params 2021-08-20 17:32:57 +02:00
Łukasz Magiera
0beb48f11d Fix error handling in SectorAddPieceToAny api impl 2021-08-19 12:56:40 +02:00
Jennifer Wang
7ff5844aa2 Merge branch 'releases' into jen/mas 2021-08-17 10:38:36 -04:00
Frrist
518b6f1d41
fix(miner): always create miner deal staging directory (#7098)
- fixes #7097

Co-authored-by: Raúl Kripalani <raul@protocol.ai>

Co-authored-by: Raúl Kripalani <raul@protocol.ai>
2021-08-17 00:16:06 +01: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
10615b53ad
Merge pull request #6853 from filecoin-project/frrist/miner-temp-file-path
feat(miner deals): create subdir to miner repo for staged deals
2021-08-16 16:19:05 -04:00
ZenGround0
eaff65c00f Remove network version panic 2021-08-12 23:50:30 -04:00