MCPcopy
hub / github.com/encode/uvicorn / connection_made

Method connection_made

uvicorn/protocols/http/h11_impl.py:91–104  ·  view source on GitHub ↗
(  # type: ignore[override]
        self, transport: asyncio.Transport
    )

Source from the content-addressed store, hash-verified

89
90 # Protocol interface
91 def connection_made( # type: ignore[override]
92 self, transport: asyncio.Transport
93 ) -> None:
94 self.connections.add(self)
95
96 self.transport = transport
97 self.flow = FlowControl(transport)
98 self.server = get_local_addr(transport)
99 self.client = get_remote_addr(transport)
100 self.scheme = "https" if is_ssl(transport) else "http"
101
102 if self.logger.level <= TRACE_LOG_LEVEL:
103 prefix = "%s:%d - " % self.client if self.client else ""
104 self.logger.log(TRACE_LOG_LEVEL, "%sHTTP connection made", prefix)
105
106 def connection_lost(self, exc: Exception | None) -> None:
107 self.connections.discard(self)

Callers 4

get_connected_protocolFunction · 0.45
get_connected_protocolFunction · 0.45

Calls 4

FlowControlClass · 0.90
get_local_addrFunction · 0.90
get_remote_addrFunction · 0.90
is_sslFunction · 0.90

Tested by 1

get_connected_protocolFunction · 0.36