From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christopher Baines Subject: Re: [PATCH 1/4] utils: Change critical section terminology to worker threads. Date: Sat, 25 Jan 2020 22:59:33 +0000 Message-ID: <875zgz87my.fsf@cbaines.net> References: <20200124194406.29638-1-mail@cbaines.net> <87r1zn8m5h.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:46380) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ivUOy-0001gW-Aq for guix-devel@gnu.org; Sat, 25 Jan 2020 17:59:41 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ivUOw-0007RH-To for guix-devel@gnu.org; Sat, 25 Jan 2020 17:59:40 -0500 In-reply-to: <87r1zn8m5h.fsf@gnu.org> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane-mx.org@gnu.org Sender: "Guix-devel" To: Ludovic =?utf-8?Q?Court=C3=A8s?= Cc: guix-devel@gnu.org --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Ludovic Court=C3=A8s writes: >> This doesn't mean all queries have to be executed one at a time though, >> providing the queries are executed outside the threads used by fibers, a= nd a >> single connection isn't used in multiple threads. > > Serialization of database accesses comes from: > > commit 4612a3a70f1e70afa4e0ce00e8cb1a7848dddf58 > Author: Cl=C3=A9ment Lassieur > Date: Sun Aug 5 13:14:44 2018 +0200 > > database: Serialize all database accesses in a thread. > > Fixes . > > Apparently at the time we weren=E2=80=99t quite sure how SQLite would per= form if > we accessed it from several threads, but you seem to suggest that it > works fine, right? Yeah, the documentation suggests it can work [1]. We're even opening the database in multi-threaded mode already (SQLITE_OPEN_NOMUTEX). 1: https://www.sqlite.org/threadsafe.html > Did you try it on a big database like that of berlin? I have an old copy of the berlin database, and it seems to work fine with that. At least the web interface that is, but if that works, everything else should work too. >> These changes start to move in this direction, first by just changing the >> terminology. > > That=E2=80=99s also welcome! I've gone ahead an pushed these patches now, as it's something I'd like to deploy prior to the Guix days. Thanks for taking a look, Chris --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQKTBAEBCgB9FiEEPonu50WOcg2XVOCyXiijOwuE9XcFAl4syFVfFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcACgkQXiijOwuE 9XdffhAAl4/J6gSeEFb0zbEbnG4e+TaSZi3PxBFjZnTK2RvxTurjoWTQdT0hJ11e 7hT81qmjRfHt3vuAD0XqTl2JIRnliWNucdhROTANoCt2w4FJub4MmFMjuITqe5/V a8D0AyGM6xpWH7Wh4q3c0LvSsgk/1YEC4cpF19d1fb449K6y0MleYyvMcOc5Te75 +BbSC5J8rgV0sW7wNQE+WzNcoj1DVhkEYrgPIaI5IhzUajIE9cL4dZmoLUKitr1j qkwbO0Pma4cFLCIqeM4ksDu0lY0WLOVLtYUlQLmwHJwviOLHxGg4tc/jw7yPt20Q F3a2DozJ1nwHNewocbBWCXp23cdMsPQarxGyV+9jvcuwbtKHMCSJYoP0fbbgOVW8 NVePSJtbBxrw8zO5GKh8DF8wLVABLn3TUe4qv1bL8/ZQUmRJO6oaSnK3pM16hA6t ZIdOQbRpzYLsC6zab9xEuG4PzqNjVydNI0/Zw5VAawXVB4MLx9Y+WUGVg39kVRbr k50KUVdDOqd4x3FT6X+Ud9B1v7zoAqsS41rpPYpM3WLMtoNsHrElMZc9C8jUj95H kLoAqI/LrZ7PqutFLyNaRfiZ70RTInM6TYrR2QyDnW4r8APsNi9/kiqwMWhyHATh zCcBVAbVsw9j0qHx4SKv/LolUpcjTBvPDhQ9owyTL1lVanAhxJo= =BO0N -----END PGP SIGNATURE----- --=-=-=--