o
    )if                     @   s   d dl Z d dlmZmZmZmZ d dlmZmZ e j	de
dd deeef deeeeef f d	eeeeeef f  fd
dZdS )    N)AnyDictOptionalUnion)AsyncTransport	TransportzjImporting from the 'elasticsearch.transport' module is deprecated. Instead import from 'elastic_transport'   category
stacklevel	node_infohostreturnc                 C   s*   t jdtdd | dg dgkrdS |S )al  
    Simple callback that takes the node info from `/_cluster/nodes` and a
    parsed connection information and return the connection information. If
    `None` is returned this node will be skipped.
    Useful for filtering nodes (by proximity for example) or if additional
    information needs to be provided for the :class:`~elasticsearch.Connection`
    class. By default master only nodes are filtered out since they shouldn't
    typically be used for API operations.
    :arg node_info: node information from `/_cluster/nodes`
    :arg host: connection information (host, port) extracted from the node info
    ziThe 'get_host_info' function is deprecated. Instead use the 'sniff_node_callback' parameter on the clientr   r	   rolesmasterN)warningswarnDeprecationWarningget)r   r    r   P/var/www/html/corbot_env/lib/python3.10/site-packages/elasticsearch/transport.pyget_host_info    s   r   )r   typingr   r   r   r   elastic_transportr   r   r   r   strintr   r   r   r   r   <module>   s   
