From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from [87.239.111.99] (localhost [127.0.0.1]) by dev.tarantool.org (Postfix) with ESMTP id DF4896EC40; Tue, 1 Jun 2021 10:52:27 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org DF4896EC40 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1622533948; bh=mQtW50a+SOCsTckUNHKH4td/F+yP0gj6NSwxlWpzqVM=; h=Date:To:References:In-Reply-To:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=cHj3WTSUSEcjC82siIZdmJB2P8VT7iIaTDeb2sjxN0v+hvDk3LiUzvvkVXrPjZYx2 qKytMUgkRw0ZunBc1KaXNUA0SNj+x8Rh7e+77EDnoNg2hLhA2Fp5LaI1cURobBBerj n4KeIBA+o0kAJ1PFpruF8XT3zrO3XKq1nV7Fojng= Received: from mail-lf1-f44.google.com (mail-lf1-f44.google.com [209.85.167.44]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id 9D0FF6EC40 for ; Tue, 1 Jun 2021 10:52:26 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 9D0FF6EC40 Received: by mail-lf1-f44.google.com with SMTP id x38so20327595lfa.10 for ; Tue, 01 Jun 2021 00:52:26 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=hLM+TCW6h8nq2uzKVZnsXz1TEXXuO6ZknTOt5C026EM=; b=oa7W5V0kxODRddfUbmYwHFVuIC0+VYSahlinRtAoi9HlDY0p3CbEAbQ5MScsw6zFzg VrnkN4nVw4S3c4vPGD5vWZCWsSkMsotYwJPwaKVlIrXPIZuGXqPJ9YHPQRpNO9xNLs89 nu50mZRhk/9qgVjMJvRYGM38NEURX9h9jtgoEQVYEEdeFH3yFQ+bh0wgf9fnionwM+sO uJWVJBGkw52sqwz62Si7zaWugp90Ftf44TYR+7tqnzzq1o6KHL6MhOQrTEmcU6ZaIwnG nXIxA5gr+KHbH0Tgt0GVMIFIq9wBSRrlhZlsVj3ddbwW5MflM+5TitytcQgpWGOGT57F NSPA== X-Gm-Message-State: AOAM5336Dt++JdAHMNXvYdQWZy9u76XtZ4Hncp+qQyJlW8YP8IQlqLz8 +TasB4YxmFy1WcFCfoh+soCW4FTkj0c= X-Google-Smtp-Source: ABdhPJzMQO2tep2R9vNzM2Y4K4ipCzatk33nTp73L7UdKLKllJrC8azmezDjV9N8oU0TWxILUVfxNQ== X-Received: by 2002:ac2:5497:: with SMTP id t23mr18127659lfk.52.1622533945504; Tue, 01 Jun 2021 00:52:25 -0700 (PDT) Received: from grain.localdomain ([5.18.171.94]) by smtp.gmail.com with ESMTPSA id c22sm2066854ljf.36.2021.06.01.00.52.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 01 Jun 2021 00:52:24 -0700 (PDT) Received: by grain.localdomain (Postfix, from userid 1000) id A04F15A0042; Tue, 1 Jun 2021 10:52:23 +0300 (MSK) Date: Tue, 1 Jun 2021 10:52:23 +0300 To: Vladislav Shpilevoy Message-ID: References: <6ed9245f407510ad3a149f62c960f89fa689909e.1622233728.git.v.shpilevoy@tarantool.org> <705ae468-7849-7928-94ff-0ecefa6fdc07@tarantool.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <705ae468-7849-7928-94ff-0ecefa6fdc07@tarantool.org> User-Agent: Mutt/2.0.7 (2021-05-04) Subject: Re: [Tarantool-patches] [PATCH 1/1] replication: check rs uuid on subscribe process X-BeenThere: tarantool-patches@dev.tarantool.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Cyrill Gorcunov via Tarantool-patches Reply-To: Cyrill Gorcunov Cc: tarantool-patches@dev.tarantool.org Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" On Sat, May 29, 2021 at 12:20:46AM +0200, Vladislav Shpilevoy wrote: > > Vlad, I didn't dive into the patch context yet but this > > use of *two* sequential calls of tt_uuid_str() is somehow > > suspicious. The tt_uuid_str uses single common buffer > > for any call which means some of tt_uuid_str() result > > will be overwritten, no? > > Nope, the static buffer is cyclic. Each tt_uuid_str() > call uses only a part of it. In total it is safe to > make ~12 tt_uuid_str() calls in a row. Because the > static buffer size is 12KB, and one tt_uuid_str() > wastes 1KB (which is not necessary, it could be much > more compact). Looks ok to me, thanks! I've been thinking if we really need to allow joining from different replicaset but don't find any scenario. Thus ACK