#NEWLINE# def add_async_request( self , method , relative_url , headers , body , source_ip , module_name = None , version = None , instance_id = None ) : #NEWLINE# #INDENT# 'Dispatch an HTTP request asynchronously.\n\n    Args:\n      method: A str containing the HTTP method of the request.\n      relative_url: A str containing path and query string of the request.\n      headers: A list of (key, value) tuples where key and value are both str.\n      body: A str containing the request body.\n      source_ip: The source ip address for the request.\n      module_name: An optional str containing the module name to service this\n          request. If unset, the request will be dispatched to the default\n          module.\n      version: An optional str containing the version to service this request.\n          If unset, the request will be dispatched to the default version.\n      instance_id: An optional str containing the instance_id of the instance to\n          service this request. If unset, the request will be dispatched to\n          according to the load-balancing for the module and version.\n    ' #NEWLINE# if module_name : #NEWLINE# #INDENT# _module = self . _get_module_with_soft_routing ( module_name , version ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# _module = self . _module_for_request ( urlparse . urlsplit ( relative_url ) . path ) #NEWLINE# #UNINDENT# inst = ( _module . get_instance ( instance_id ) if instance_id else None ) #NEWLINE# port = ( _module . get_instance_port ( instance_id ) if instance_id else body . balanced_port ) #NEWLINE# environ = _module . build_request_environ ( method , relative_url , headers , body , source_ip , port ) #NEWLINE# _THREAD_POOL . submit ( self . _handle_request , environ , start_response_utils . null_start_response , _module , inst , catch_and_log_exceptions = True )