Skip to content

Commit

Permalink
save
Browse files Browse the repository at this point in the history
  • Loading branch information
AskAlexSharov committed Dec 9, 2023
1 parent aeec5d6 commit 3c4d7cc
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions downloader/downloader.proto
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,16 @@ option go_package = "./downloader;downloader";
package downloader;

service Downloader {
// Erigon's invariant: download new files only at first sync cycle. All other files erigon produce by self and seed.
// after this request: downloader will skip all download requests - if corresponding file doesn't exists on FS yet.
// But next things will work: add new file for seeding, download some uncomplete parts of existing files (because of Verify found some bad parts)
// Erigon "download once" - means restart/upgrade will not download files (and will be fast)
// After "download once" - Erigon will produce and seed new files
// Downloader will able: seed new files (already existing on FS), download uncomplete parts of existing files (if Verify found some bad parts)
rpc ProhibitNewDownloads (ProhibitNewDownloadsRequest) returns (google.protobuf.Empty) {}

// Adding new file to downloader: non-existing files it will download, existing - seed.
rpc Add (AddRequest) returns (google.protobuf.Empty) {}
rpc Delete (DeleteRequest) returns (google.protobuf.Empty) {}
// Trigger verification of files
// If some part of file is bad - such part will be re-downloaded (without returning error)
rpc Verify (VerifyRequest) returns (google.protobuf.Empty) {}
rpc Stats (StatsRequest) returns (StatsReply) {}
}
Expand Down

0 comments on commit 3c4d7cc

Please sign in to comment.