From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id C94BC22520 for ; Mon, 23 Apr 2018 08:31:01 -0400 (EDT) Received: from turing.freelists.org ([127.0.0.1]) by localhost (turing.freelists.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 6eUi-0IuiDfT for ; Mon, 23 Apr 2018 08:31:01 -0400 (EDT) Received: from smtp37.i.mail.ru (smtp37.i.mail.ru [94.100.177.97]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTPS id 27A51224FA for ; Mon, 23 Apr 2018 08:31:00 -0400 (EDT) Date: Mon, 23 Apr 2018 15:31:08 +0300 From: Alexander Turenko Subject: [tarantool-patches] Re: [PATCH 6/8] netbox: introduce fiber-async API Message-ID: <20180423123108.ensm2xcd3onbfnpu@tkn_work_nb> References: <49a50d32a154959aa786ec2a85a4f74792d7ae09.1523903144.git.v.shpilevoy@tarantool.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <49a50d32a154959aa786ec2a85a4f74792d7ae09.1523903144.git.v.shpilevoy@tarantool.org> Sender: tarantool-patches-bounce@freelists.org Errors-to: tarantool-patches-bounce@freelists.org Reply-To: tarantool-patches@freelists.org List-help: List-unsubscribe: List-software: Ecartis version 1.0.0 List-Id: tarantool-patches List-subscribe: List-owner: List-post: List-archive: To: Vladislav Shpilevoy Cc: tarantool-patches@freelists.org Hi Vlad! Minor wording comments are below (Vlad asks to track it here). WBR, Alexander Turenko. On Mon, Apr 16, 2018 at 09:39:16PM +0300, Vladislav Shpilevoy wrote: > Now any netbox call blocks a caller-fiber until a result is read > from a socket, or time is out. To use it asynchronously it is > necessary to create a fiber per request. Sometimes it is > unwanted - for example if RPS is very high (for example, about > 100k), and latency is about 1 second. Or when it is neccessary > to send multiple requests in paralles and then collect responses > (map-reduce). Paralles -> parallel. > + function request_index:wait_result(timeout) > ... > + if not self:is_ready() then > + -- When a response is ready before timeout, the > + -- waiting client is waked up spuriously. Do you mean prematurely?