googleapis / googleapis/google-cloud-python
auth: configure_mtls_channel() discards existing session configuration
- Ngôn ngữ chính
- Python
- Star
- 5.4k
- Fork
- 1.8k
- Merge trung bình
- 3 ngày 4 giờ
- Pull request đã merge (30 ngày)
- 122
Mô tả
In `AsyncAuthorizedSession.configure_mtls_channel()` (`packages/google-auth/google/auth/aio/transport/sessions.py`), configuring mutual TLS replaces `self._auth_request` with a newly constructed `aiohttp.ClientSession` and `aiohttp.TCPConnector`:
```python
connector = aiohttp.TCPConnector(ssl=ssl_context)
new_session = aiohttp.ClientSession(connector=connector)
old_auth_request = self._auth_request
self._auth_request = AiohttpRequest(session=new_session)
```
Because `new_session` is instantiated from scratch with default arguments, we lose any custom configurations provided by callers on the initial session, such as connection pool limits, timeouts, etc.
Hướng dẫn đóng góp
Đánh giá
Issue này chưa được đánh giá.