Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1vciE2-009v3D-2S for pgsql-hackers@arkaria.postgresql.org; Mon, 05 Jan 2026 10:54:15 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1vciDz-001Zqs-2s for pgsql-hackers@arkaria.postgresql.org; Mon, 05 Jan 2026 10:54:12 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1vciDz-001Zqj-1n for pgsql-hackers@lists.postgresql.org; Mon, 05 Jan 2026 10:54:12 +0000 Received: from mail-wm1-x32a.google.com ([2a00:1450:4864:20::32a]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1vciDx-004dgQ-1B for pgsql-hackers@lists.postgresql.org; Mon, 05 Jan 2026 10:54:11 +0000 Received: by mail-wm1-x32a.google.com with SMTP id 5b1f17b1804b1-4779ce2a624so110311935e9.2 for ; Mon, 05 Jan 2026 02:54:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cybertec.at; s=google; t=1767610448; x=1768215248; darn=lists.postgresql.org; h=message-id:date:content-transfer-encoding:mime-version:comments :references:in-reply-to:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=e2LNSn2EIJGBj6fJx9dKyFqT2TfkVYWjtlWPn7Lrki8=; b=qxvFhauQhlBfMi/l+Do+nKvpNkLKIJ4lYuDY65OF2LzRbWOZxSF924ai3c71Psy73s J2GQLIzXEy8y1FM9rCvYz/a6ZHrMAk7d0nc/lkuaN2fogFzI4A5OI8N+AYCj+7CIb7T7 aWrPnNutV0tNp219TQAa9AQSwOKiroi2Fn9yhMCQsnhzuvLdHF0tCJDYurZ0uHNM1Gy7 vUVm8iH1LIfQeuV8qFMftf5oNfBWOsuqIKgWL6jQgcRTEXumIoo5AaEzC6M7dqY/Evkb 07zlqEWxtOMZM2ka0LRvzYvhGnbouKg+tL4ZrLAfMf/uu/qX0t994RZ2fbTH1wTtEqMW 0oCg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1767610448; x=1768215248; h=message-id:date:content-transfer-encoding:mime-version:comments :references:in-reply-to:subject:cc:to:from:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=e2LNSn2EIJGBj6fJx9dKyFqT2TfkVYWjtlWPn7Lrki8=; b=mA6/I1HdSFwHemRuFlJY+K8Xo4u5d5/xPReLcgDMdhhWVupMhpayJ2zs3L/VPTyO4c nMA6dPQVD2WR5llPr7YCd61gEMQCT6tgyprVct20sGvZgJ/eFajN4JV1amlfH7hOny77 1sjSvE5XbiYPxwbzxwlmzMjCrcyH7cduag4WulUFkeFxhcl+FgmTKMDQGH5801igquh9 yt6jqv8slnlI0oSUQfvj4ZNBH+EZaKDXctt6FW9EyOJKlDax3efYFSAdzLEzQbIVIdoG VrtyaX0Edh0QN/N2ltNtX/SM5vOvMBzeWaiqR95xHbleDhCiKvcSBNFT9QhwddhnB5NT aYmQ== X-Forwarded-Encrypted: i=1; AJvYcCWPWBfBjQbjXvHV+iKy8rJUSR96uD3KwKLN3GH5eknunGVbTiwhDHMhow/poNergav2jrdmCiobHzbL8GAm@lists.postgresql.org X-Gm-Message-State: AOJu0YzPwlaJf0+mD8MUJewCBtsoqOEeq+EyXbxkh7QTKlVtzqpM4adn uudJLsSAYyvaXtwGrxsvkFWVcklwoKXDAjmu8HBWqu1896jBiFrGl4YbnxpRHWtRRPU= X-Gm-Gg: AY/fxX6SbR49fT7XLwEhPbb3sKCyWdHpl5W7V129Nj5ii0UWpSCf/iPwSSCSsFd+TM5 F3fneWlAc7CB0GV9QsGTdwlGZsNYYqGIlFbnmFuPoVlq+LYIhsybk9Aktk5b25WxE8cCMFFMKZh 46EmMaFwlSMmxHoX/Ep7JNzO9cB2n2Z4l91xfR9X13x/ehoyL0pDWGOt6AuX7PCafrw3bDAXuoa SgKe/FjVKo+mruZVPZktb29xFItOgcLa4yWApGQ1pLmd7zKDOELby3q3wxeKvK1xeSinIHQehnY LaqwDNxvtwowdWAMEkXo/Dx2RSjoS/hWsvMP3OY9D63dBrxRpc3e2AVhNAFmUZRyIP8Z8ElWA7C bED2jjdDNBj7gp479WQrjr6oxyxJXF0e0e8OG/uM4i8xwEMXs0R1SAhgeM4KXilcEKTlVKl6F2J 9IyHepMCb1xdid5fPoRY1c/Yfy X-Google-Smtp-Source: AGHT+IEhdavQz2bzIZPbbvTrgtU/o8UcIJauLQT/XISaz2iSmUDvtkpElg7X1sgxFUEvNYGs1VNZdw== X-Received: by 2002:a05:600c:c091:b0:477:7b9a:bb07 with SMTP id 5b1f17b1804b1-47d195a98d5mr488040935e9.35.1767610448052; Mon, 05 Jan 2026 02:54:08 -0800 (PST) Received: from localhost (109-81-168-246.rct.o2.cz. [109.81.168.246]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-47d6d143f57sm147139675e9.4.2026.01.05.02.54.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Jan 2026 02:54:07 -0800 (PST) From: Antonin Houska To: Mihail Nikalayeu cc: Alvaro Herrera , Pg Hackers , Robert Treat Subject: Re: Adding REPACK [concurrently] In-reply-to: References: <202510301734.pj4uds3mqxx4@alvherre.pgsql> <116433.1764870207@localhost> <171530.1765306357@localhost> Comments: In-reply-to Mihail Nikalayeu message dated "Thu, 18 Dec 2025 02:47:00 +0100." X-Mailer: MH-E 8.6+git; nmh 1.8; GNU Emacs 28.3 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Date: Mon, 05 Jan 2026 11:54:07 +0100 Message-ID: <12236.1767610447@localhost> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Mihail Nikalayeu wrote: > Hello! >=20 > On Sat, Dec 13, 2025 at 7:45=E2=80=AFPM Mihail Nikalayeu > wrote: > > Stress tests for REPACK concurrently in attachment. >=20 > To run: > ninja && meson test --suite setup && meson test --print-errorlogs > --suite amcheck *007* > ninja && meson test --suite setup && meson test --print-errorlogs > --suite amcheck *008* Thanks for running the tests! > Results for v28: >=20 > Up to " v28-0005-Use-background-worker-to-do-logical-decoding.patch": >=20 > Technically it passes, but sometimes I saw 0% CPU usage for long > periods with such stacks (looks like it happens for 0008 more often): ... > Probably it is because > > 100000L, /* XXX Tune the delay. */ >=20 > 100 seconds is clearly too much. I confused milliseconds with microseconds. Since I was only running the code with debugger, the long delays didn't appear to be a problem. Instead of tuning the timeout, I'm thinking of introducing a condition variable that signals WAL flushing. > For "v28-0006-Use-multiple-snapshots-to-copy-the-data.patch": >=20 > 0007: crash with >=20 > TRAP: failed Assert("portal->portalSnapshot =3D=3D GetActiveSnapshot()"), > File: "../src/backend/tcop/pquery.c", Line: 1169, PID: 178414 Thanks. I'll check when I have time for this part. --=20 Antonin Houska Web: https://www.cybertec-postgresql.com