MCPcopy Create free account
hub / github.com/apache/mesos / send

Method send

3rdparty/libprocess/src/process.cpp:1859–1888  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1857
1858
1859void SocketManager::send(Encoder* encoder, bool persist, const Socket& socket)
1860{
1861 CHECK(encoder != nullptr);
1862
1863 synchronized (mutex) {
1864 if (sockets.count(socket) > 0) {
1865 // Update whether or not this socket should get disposed after
1866 // there is no more data to send.
1867 if (!persist) {
1868 dispose.insert(socket);
1869 }
1870
1871 if (outgoing.count(socket) > 0) {
1872 outgoing[socket].push(encoder);
1873 encoder = nullptr;
1874 } else {
1875 // Initialize the outgoing queue.
1876 outgoing[socket];
1877 }
1878 } else {
1879 VLOG(1) << "Attempting to send on a no longer valid socket!";
1880 delete encoder;
1881 encoder = nullptr;
1882 }
1883 }
1884
1885 if (encoder != nullptr) {
1886 internal::send(encoder, socket);
1887 }
1888}
1889
1890
1891void SocketManager::send(

Callers

nothing calls this directly

Calls 7

NoneClass · 0.85
transportFunction · 0.85
sendFunction · 0.70
connectSocketFunction · 0.70
bindFunction · 0.50
containsMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected