golden hour
/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/__pycache__
⬆️ Go Up
Upload
File/Folder
Size
Actions
__init__.cpython-310.pyc
378 B
Del
OK
_locale_data.cpython-310.pyc
3.23 KB
Del
OK
auth.cpython-310.pyc
39.18 KB
Del
OK
autoreload.cpython-310.pyc
7.02 KB
Del
OK
concurrent.cpython-310.pyc
17.24 KB
Del
OK
curl_httpclient.cpython-310.pyc
12.8 KB
Del
OK
escape.cpython-310.pyc
9.89 KB
Del
OK
gen.cpython-310.pyc
38.39 KB
Del
OK
http1connection.cpython-310.pyc
19.47 KB
Del
OK
httpclient.cpython-310.pyc
25.19 KB
Del
OK
httpserver.cpython-310.pyc
11.45 KB
Del
OK
httputil.cpython-310.pyc
29.84 KB
Del
OK
ioloop.cpython-310.pyc
33.19 KB
Del
OK
iostream.cpython-310.pyc
42.97 KB
Del
OK
locale.cpython-310.pyc
15.22 KB
Del
OK
locks.cpython-310.pyc
16.61 KB
Del
OK
log.cpython-310.pyc
8.07 KB
Del
OK
netutil.cpython-310.pyc
14.32 KB
Del
OK
options.cpython-310.pyc
19.63 KB
Del
OK
process.cpython-310.pyc
10.27 KB
Del
OK
queues.cpython-310.pyc
11.29 KB
Del
OK
routing.cpython-310.pyc
21.08 KB
Del
OK
simple_httpclient.cpython-310.pyc
16.08 KB
Del
OK
stack_context.cpython-310.pyc
10.65 KB
Del
OK
tcpclient.cpython-310.pyc
6.49 KB
Del
OK
tcpserver.cpython-310.pyc
10.06 KB
Del
OK
template.cpython-310.pyc
30.52 KB
Del
OK
testing.cpython-310.pyc
24.61 KB
Del
OK
util.cpython-310.pyc
13.72 KB
Del
OK
web.cpython-310.pyc
105.22 KB
Del
OK
websocket.cpython-310.pyc
39.08 KB
Del
OK
wsgi.cpython-310.pyc
11.5 KB
Del
OK
Edit: simple_httpclient.cpython-310.pyc
o �xea � @ s� d dl mZmZmZ d dlmZmZ d dlmZ d dl m Z mZmZm Z mZ d dlmZ d dlmZmZ d dlmZ d dlmZmZmZ d d lmZ d d lmZ d dlmZ d dlmZ d d l Z d d l!Z!d d l"Z"d d l#Z#d d l$Z$d d l%Z%d d l&Z&d dl'm(Z( er�d d l)m*Z+ nd d l+Z+zd d l,Z,W n e-y� d Z,Y nw zd d l.Z.W n e-y� d Z.Y nw dd� Z/G dd� de�Z0G dd� dej1�Z2e3dkr�e�4e0� e � d S d S )� )�absolute_import�division�print_function)�utf8�_unicode)�gen)�HTTPResponse� HTTPError�AsyncHTTPClient�main� _RequestProxy)�httputil)�HTTP1Connection�HTTP1ConnectionParameters)�StreamClosedError)�Resolver�OverrideResolver�_client_ssl_defaults)�gen_log)� stack_context)� TCPClient)�PY3N)�BytesIOc C s t d u rtd��t �� S )NzCThe 'certifi' package is required to use https in simple_httpclient)�certifi� Exception�where� r r �V/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/simple_httpclient.py�_default_ca_certs, s r c sp e Zd ZdZ d� fdd� Z� fdd�Zd d � Zdd� Zd d� Zdd� Z dd� Z dd� Zddd�Z� Z S )�SimpleAsyncHTTPClientai Non-blocking HTTP client with no external dependencies. This class implements an HTTP 1.1 client on top of Tornado's IOStreams. Some features found in the curl-based AsyncHTTPClient are not yet supported. In particular, proxies are not supported, connections are not reused, and callers cannot select the network interface to be used. � N� @c s� t t| �j||d� || _t�� | _i | _i | _|| _ || _ || _|r*|| _d| _ n t|d�| _d| _ |dur?t| j|d�| _t| j|d�| _dS )a Creates a AsyncHTTPClient. Only a single AsyncHTTPClient instance exists per IOLoop in order to provide limitations on the number of pending connections. ``force_instance=True`` may be used to suppress this behavior. Note that because of this implicit reuse, unless ``force_instance`` is used, only the first call to the constructor actually uses its arguments. It is recommended to use the ``configure`` method instead of the constructor to ensure that arguments take effect. ``max_clients`` is the number of concurrent requests that can be in progress; when this limit is reached additional requests will be queued. Note that time spent waiting in this queue still counts against the ``request_timeout``. ``hostname_mapping`` is a dictionary mapping hostnames to IP addresses. It can be used to make local DNS changes when modifying system-wide settings like ``/etc/hosts`` is not possible or desirable (e.g. in unittests). ``max_buffer_size`` (default 100MB) is the number of bytes that can be read into memory at once. ``max_body_size`` (defaults to ``max_buffer_size``) is the largest response body that the client will accept. Without a ``streaming_callback``, the smaller of these two limits applies; with a ``streaming_callback`` only ``max_body_size`` does. .. versionchanged:: 4.2 Added the ``max_body_size`` argument. )�defaultsF)�io_loopTN)�resolver�mapping)r$ r# )�superr � initialize�max_clients�collections�deque�queue�active�waiting�max_buffer_size�max_header_size� max_body_sizer$ �own_resolverr r r � tcp_client) �selfr# r( Zhostname_mappingr. r$ r"