storj/satellite/internalpb/inspector.proto
Egon Elbre d57873fd45 satellite/overlay: remove Inspector
Currently overlay.Inspector had two rpc methods and both of them were
unimplemented.

Change-Id: I1a2ecc7b7113898fa234a1c1fe451c8cc9e2ee81
2021-03-29 12:26:10 +03:00

74 lines
2.6 KiB
Protocol Buffer

// Copyright (C) 2019 Storj Labs, Inc.
// See LICENSE for copying information.
syntax = "proto3";
option go_package = "storj.io/storj/satellite/internalpb";
import "gogo.proto";
import "node.proto";
import "pointerdb.proto";
package satellite.inspector;
service IrreparableInspector {
// ListIrreparableSegments returns damaged segments
rpc ListIrreparableSegments(ListIrreparableSegmentsRequest) returns (ListIrreparableSegmentsResponse);
}
message ListIrreparableSegmentsRequest {
int32 limit = 1;
bytes last_seen_segment_path = 2;
}
message ListIrreparableSegmentsResponse {
repeated IrreparableSegment segments = 1;
}
message IrreparableSegment {
bytes path = 1;
pointerdb.Pointer segment_detail = 2;
int32 lost_pieces = 3;
int64 last_repair_attempt = 4;
int64 repair_attempt_count = 5;
}
service HealthInspector {
// ObjectHealth will return stats about the health of an object
rpc ObjectHealth(ObjectHealthRequest) returns (ObjectHealthResponse) {}
// SegmentHealth will return stats about the health of a segment
rpc SegmentHealth(SegmentHealthRequest) returns (SegmentHealthResponse) {}
}
message ObjectHealthRequest {
bytes encrypted_path = 1; // object encrypted path
bytes bucket = 2; // object bucket name
bytes project_id = 3; // object project id
int64 start_after_segment = 4; // Get all segments after specified segment index
int64 end_before_segment = 5; // Stop at segment before specified segment index
int32 limit = 6; // Max number of segments that are checked
}
message ObjectHealthResponse {
repeated SegmentHealth segments = 1; // actual segment info
pointerdb.RedundancyScheme redundancy = 2; // expected segment info
}
message SegmentHealthRequest {
bytes bucket = 1; // segment bucket name
bytes encrypted_path = 2; // segment encrypted path
int64 segment_index = 3; // segment index
bytes project_id = 4; // segment project id
}
message SegmentHealthResponse {
SegmentHealth health = 1; // Information about a segment's health
pointerdb.RedundancyScheme redundancy = 2; // expected segment info
}
message SegmentHealth {
repeated bytes healthy_ids = 1 [(gogoproto.customtype) = "NodeID"]; // online + not disqualified
repeated bytes unhealthy_ids = 2 [(gogoproto.customtype) = "NodeID"]; // online + disqualified
repeated bytes offline_ids = 3 [(gogoproto.customtype) = "NodeID"]; // offline
bytes segment = 4; // path formatted segment index
}