Report pmtu blackholes and upperbounds by occurences
Summary: We should report blackholes and upperbounds by occurrence.
MODIFY
quic/d6d/QuicD6DStateFunctions.cpp
quic/d6d/QuicD6DStateFunctions.cpp
@@ -25,8 +25,7 @@ static TimePoint reportUpperBound(QuicConnectionStateBase& conn) {
const auto lastProbeSize = d6d.lastProbe->packetSize;
const auto now = Clock::now();
- QUIC_STATS(
- conn.statsCallback, onConnectionPMTUUpperBoundDetected, lastProbeSize);
+ QUIC_STATS(conn.statsCallback, onConnectionPMTUUpperBoundDetected);
if (conn.instrumentationObservers_.size() > 0) {
InstrumentationObserver::PMTUUpperBoundEvent upperBoundEvent(
now,
@@ -54,10 +53,7 @@ static TimePoint reportUpperBound(QuicConnectionStateBase& conn) {
static TimePoint reportBlackhole(
QuicConnectionStateBase& conn,
const OutstandingPacket& packet) {
- QUIC_STATS(
- conn.statsCallback,
- onConnectionPMTUBlackholeDetected,
- packet.metadata.encodedSize);
+ QUIC_STATS(conn.statsCallback, onConnectionPMTUBlackholeDetected);
auto& d6d = conn.d6d;
const auto now = Clock::now();
if (conn.instrumentationObservers_.size() > 0) {

MODIFY
quic/samples/echo/LogQuicStats.h
quic/samples/echo/LogQuicStats.h
@@ -157,16 +157,12 @@ class LogQuicStats : public quic::QuicTransportStatsCallback {
VLOG(2) << prefix_ << "onConnectionPMTURaised";
}
- void onConnectionPMTUBlackholeDetected(
- uint64_t pmtuAtBlackholeTime) override {
- VLOG(2) << prefix_
- << "onConnectionPMTUBlackholeDetected pmtuAtBlackholeTime="
- << pmtuAtBlackholeTime;
+ void onConnectionPMTUBlackholeDetected() override {
+ VLOG(2) << prefix_ << "onConnectionPMTUBlackholeDetected";
}
- void onConnectionPMTUUpperBoundDetected(uint64_t pmtuUpperBound) override {
- VLOG(2) << prefix_ << "onConnectionPMTUUpperBoundDetected pmtuUpperBound="
- << pmtuUpperBound;
+ void onConnectionPMTUUpperBoundDetected() override {
+ VLOG(2) << prefix_ << "onConnectionPMTUUpperBoundDetected";
}
private:

MODIFY
quic/state/QuicTransportStatsCallback.h
quic/state/QuicTransportStatsCallback.h
@@ -140,10 +140,9 @@ class QuicTransportStatsCallback {
virtual void onConnectionPMTURaised() = 0;
- virtual void onConnectionPMTUBlackholeDetected(
- uint64_t pmtuAtBlackholeTime) = 0;
+ virtual void onConnectionPMTUBlackholeDetected() = 0;
- virtual void onConnectionPMTUUpperBoundDetected(uint64_t pmtuUpperBound) = 0;
+ virtual void onConnectionPMTUUpperBoundDetected() = 0;
static const char* toString(ConnectionCloseReason reason) {
switch (reason) {

MODIFY
quic/state/test/MockQuicStats.h
quic/state/test/MockQuicStats.h
@@ -49,8 +49,8 @@ class MockQuicStats : public QuicTransportStatsCallback {
MOCK_METHOD1(onUDPSocketWriteError, void(SocketErrorType));
MOCK_METHOD0(onConnectionD6DStarted, void());
MOCK_METHOD0(onConnectionPMTURaised, void());
- MOCK_METHOD1(onConnectionPMTUBlackholeDetected, void(uint64_t));
- MOCK_METHOD1(onConnectionPMTUUpperBoundDetected, void(uint64_t));
+ MOCK_METHOD0(onConnectionPMTUBlackholeDetected, void());
+ MOCK_METHOD0(onConnectionPMTUUpperBoundDetected, void());
};
class MockQuicStatsFactory : public QuicTransportStatsCallbackFactory {

Report pmtu blackholes and upperbounds by occurences

Summary: We should report blackholes and upperbounds by occurrence.

Reviewed By: avasylev

Differential Revision: D24400499

fbshipit-source-id: 2085317943ce378599e734567ff19ae9e7500ed9