MCPcopy Create free account
hub / github.com/apache/trafficserver / new_connection

Method new_connection

plugins/experimental/memcache/tsmemcache.cc:151–167  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

149}
150
151void
152MC::new_connection(NetVConnection *netvc, EThread *thread)
153{
154 nvc = netvc;
155 mutex = new_ProxyMutex();
156 rbuf = new_MIOBuffer(MAX_IOBUFFER_SIZE);
157 rbuf->water_mark = TSMEMCACHE_TMP_CMD_BUFFER_SIZE;
158 reader = rbuf->alloc_reader();
159 wbuf = new_empty_MIOBuffer(BUFFER_SIZE_INDEX_32K);
160 cbuf = 0;
161 writer = wbuf->alloc_reader();
162 SCOPED_MUTEX_LOCK(lock, mutex, thread);
163 rvio = nvc->do_io_read(this, INT64_MAX, rbuf);
164 wvio = nvc->do_io_write(this, 0, writer);
165 header.magic = TSMEMCACHE_HEADER_MAGIC;
166 read_from_client();
167}
168
169int
170MC::die()

Callers 1

main_eventMethod · 0.45

Calls 4

new_ProxyMutexFunction · 0.85
alloc_readerMethod · 0.80
do_io_readMethod · 0.45
do_io_writeMethod · 0.45

Tested by

no test coverage detected