Index: common/logdog/fetcher/fetcher.go |
diff --git a/common/logdog/fetcher/fetcher.go b/common/logdog/fetcher/fetcher.go |
index 279993d2e8475716dc94821ab5abb3ff67a1d072..ab1865d440fd1d4252385af09101fc6629e7f007 100644 |
--- a/common/logdog/fetcher/fetcher.go |
+++ b/common/logdog/fetcher/fetcher.go |
@@ -31,7 +31,7 @@ type LogRequest struct { |
// Index is the starting log index to request. |
Index types.MessageIndex |
// Count, if >0, is the maximum number of log entries to request. |
- Count int |
+ Count int64 |
// Bytes, if >0, is the maximum number of log bytes to request. At least one |
// log must be returned regardless of the byte limit. |
Bytes int64 |
@@ -160,7 +160,7 @@ func (f *Fetcher) NextLogEntry() (*logpb.LogEntry, error) { |
type fetchRequest struct { |
index types.MessageIndex |
- count int |
+ count int64 |
bytes int64 |
respC chan *fetchResponse |
} |
@@ -252,7 +252,7 @@ func (f *Fetcher) fetch(c context.Context) { |
logFetchC = logFetchBaseC |
req := fetchRequest{ |
index: nextFetchIndex, |
- count: int(fetchCount), |
+ count: fetchCount, |
bytes: fetchBytes, |
respC: logFetchC, |
} |
@@ -362,7 +362,7 @@ func (f *Fetcher) fetchLogs(c context.Context, req *fetchRequest) { |
"index": req.index, |
"delay": f.o.Delay, |
}.Infof(c, "No logs returned. Sleeping...") |
- clock.Sleep(c, f.o.Delay) |
+ clock.CancelSleep(c, f.o.Delay) |
} |
} |
} |