From mboxrd@z Thu Jan 1 00:00:00 1970 From: Danny Milosavljevic Subject: bug#32234: [PATCH 2/2] database: Serialize all database accesses in a thread. Date: Mon, 27 Aug 2018 14:41:48 +0200 Message-ID: <20180827144120.13c76371@scratchpost.org> References: <20180806192736.1747-1-clement@lassieur.org> <20180806192736.1747-2-clement@lassieur.org> <87zhxih2no.fsf@gnu.org> <87lg8tb4rz.fsf@lassieur.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; boundary="Sig_//DUe=SY8HXh5Idu5OJ1R1+1"; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:39832) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fuH6o-0003FJ-DT for bug-guix@gnu.org; Mon, 27 Aug 2018 08:59:09 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fuGqI-0002mA-8J for bug-guix@gnu.org; Mon, 27 Aug 2018 08:42:03 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:56881) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fuGqI-0002m2-4l for bug-guix@gnu.org; Mon, 27 Aug 2018 08:42:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1fuGqH-0003bS-SB for bug-guix@gnu.org; Mon, 27 Aug 2018 08:42:01 -0400 Sender: "Debbugs-submit" Resent-Message-ID: In-Reply-To: <87lg8tb4rz.fsf@lassieur.org> List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org Sender: "bug-Guix" To: =?UTF-8?Q?Cl=C3=A9ment?= Lassieur Cc: 32234@debbugs.gnu.org --Sig_//DUe=SY8HXh5Idu5OJ1R1+1 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hi Cl=C3=A9ment, in the future I plan on making the actual bin/evaluate use another database= connection in order for the web interface to be isolated while it's querying. Otherwise - as it is now in master - it can happen that while you are query= ing one page, half of the things have different values than you requested - which i= s really weird. For example right now you could query for a row with status=3D42 and get ba= ck data with status=3D43 (because it has been changed in the mean time). It's better to have serializable transaction isolation to prevent this. Th= at means that each connection will have its own worldview that is fixed at the begin= ning of the connection's transaction. The worldview will update only once a new tr= ansaction starts. Therefore, it would be good for writers to have their own connection in the= long run (really, for the readers to have their own connection - but that comes out = the same). So it would be good to keep this in mind. --Sig_//DUe=SY8HXh5Idu5OJ1R1+1 Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEEds7GsXJ0tGXALbPZ5xo1VCwwuqUFAluD8YwACgkQ5xo1VCww uqXX/QgAqCMZppz63XdQ6aeYB0oAjKgqBbwgOHJLUrKN802OcoWMdlZtLlt/8qnq kb+z4OtTu2YkQW2jvMxFz6AsmpzLQpxklBcJSxb6p1orpXprtULwGPN2TEIaCEPH dwehWX99xlJIdvI4yRndD7ypSFJLPcrZGfzNsC8lATkD2GZVApxRe2RMsJ+BdUCL 9JMXoPYuw1kEW1FWzPjQ9BH68+nYYx5GiL+iVWlE2OY5giz48JXJhOyti7CGVDzJ MDCUPmrTFswOe4CRICS6qWOMyLtGYte1gSeSPngGLaR1BdSLRLq3fDbLIqlAqE84 uFg0NDnuf10YRwnkL9Z+aDgXGOS/lw== =niAZ -----END PGP SIGNATURE----- --Sig_//DUe=SY8HXh5Idu5OJ1R1+1--