Project import generated by Copybara.
PiperOrigin-RevId: 267274408
This commit is contained in:
@@ -108,10 +108,25 @@ class FixedSizeInputStreamHandler : public DefaultInputStreamHandler {
|
||||
}
|
||||
|
||||
// Returns the lowest timestamp of a packet ready to process.
|
||||
<<<<<<< HEAD
|
||||
Timestamp MinTimestampOrBound() {
|
||||
Timestamp min_bound = Timestamp::Done();
|
||||
for (const auto& stream : input_stream_managers_) {
|
||||
min_bound = std::min(min_bound, stream->MinTimestampOrBound(nullptr));
|
||||
=======
|
||||
Timestamp MinTimestampToProcess() {
|
||||
Timestamp min_bound = Timestamp::Done();
|
||||
for (const auto& stream : input_stream_managers_) {
|
||||
bool empty;
|
||||
Timestamp stream_timestamp = stream->MinTimestampOrBound(&empty);
|
||||
// If we're using the stream's *bound*, we only want to process up to the
|
||||
// packet *before* the bound, because a packet may still arrive at that
|
||||
// time.
|
||||
if (empty) {
|
||||
stream_timestamp = PreviousAllowedInStream(stream_timestamp);
|
||||
}
|
||||
min_bound = std::min(min_bound, stream_timestamp);
|
||||
>>>>>>> Project import generated by Copybara.
|
||||
}
|
||||
return min_bound;
|
||||
}
|
||||
@@ -199,7 +214,11 @@ class FixedSizeInputStreamHandler : public DefaultInputStreamHandler {
|
||||
}
|
||||
// input_timestamp is recalculated here to process the most recent packets.
|
||||
EraseSurplusPackets(true);
|
||||
<<<<<<< HEAD
|
||||
input_timestamp = MinTimestampOrBound();
|
||||
=======
|
||||
input_timestamp = MinTimestampToProcess();
|
||||
>>>>>>> Project import generated by Copybara.
|
||||
DefaultInputStreamHandler::FillInputSet(input_timestamp, input_set);
|
||||
pending_ = false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user