MCPcopy Create free account
hub / github.com/apache/brpc / AddOutputBytes

Method AddOutputBytes

src/brpc/socket.cpp:2923–2928  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2921 }
2922}
2923void Socket::AddOutputBytes(size_t bytes) {
2924 GetOrNewSharedPart()->out_size.fetch_add(bytes, butil::memory_order_relaxed);
2925 _last_writetime_us.store(butil::cpuwide_time_us(),
2926 butil::memory_order_relaxed);
2927 CancelUnwrittenBytes(bytes);
2928}
2929void Socket::AddOutputMessages(size_t count) {
2930 GetOrNewSharedPart()->out_num_messages.fetch_add(count, butil::memory_order_relaxed);
2931}

Callers 1

KeepWriteMethod · 0.80

Calls 3

cpuwide_time_usFunction · 0.85
fetch_addMethod · 0.80
storeMethod · 0.45

Tested by

no test coverage detected