From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp47.i.mail.ru (smtp47.i.mail.ru [94.100.177.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id 4EA8D445320 for ; Sun, 5 Jul 2020 20:05:26 +0300 (MSK) References: <1593757997-4145-1-git-send-email-alyapunov@tarantool.org> <1593757997-4145-10-git-send-email-alyapunov@tarantool.org> From: Vladislav Shpilevoy Message-ID: Date: Sun, 5 Jul 2020 19:05:24 +0200 MIME-Version: 1.0 In-Reply-To: <1593757997-4145-10-git-send-email-alyapunov@tarantool.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Subject: Re: [Tarantool-patches] [PATCH 09/15] tx: introduce prepare sequence number List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Aleksandr Lyapunov , tarantool-patches@dev.tarantool.org Thanks for the patch! What are these psns? What are the difference with txn->id and with lsn? > diff --git a/src/box/txn.h b/src/box/txn.h > index e2194b6..cd1665f 100644 > --- a/src/box/txn.h > +++ b/src/box/txn.h > @@ -214,6 +214,11 @@ struct txn { > * Valid IDs start from 1. > */ > int64_t id; > + /** > + * A sequential ID that is assigned when the TX become prepared. > + * Transactions are committed on in that order. > + */ > + int64_t psn; Why can't you use id? > /** Status of the TX */ > enum txn_status status; > /** List of statements in a transaction. */