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 1wAlel-000J03-0W for pgsql-hackers@arkaria.postgresql.org; Thu, 09 Apr 2026 09:26:35 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1wAlej-004uah-1k for pgsql-hackers@arkaria.postgresql.org; Thu, 09 Apr 2026 09:26:34 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1wAlej-004uaZ-0m for pgsql-hackers@lists.postgresql.org; Thu, 09 Apr 2026 09:26:34 +0000 Received: from mail-wm1-x333.google.com ([2a00:1450:4864:20::333]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1wAleh-000000008pC-3Exv for pgsql-hackers@lists.postgresql.org; Thu, 09 Apr 2026 09:26:32 +0000 Received: by mail-wm1-x333.google.com with SMTP id 5b1f17b1804b1-4838c15e3cbso5232915e9.3 for ; Thu, 09 Apr 2026 02:26:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cybertec.at; s=google; t=1775726791; x=1776331591; 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=q9Nzk1LZvHLUlfOK8EzmGD671Kep8Lkhha7eumOX+U4=; b=kRpXENGEqBX1W21/w/PGxA3EqFJGu/XKA2F+xxFt8CQ1mADmUyFC5nMKji/dPrkMjp K13oDTrx/Xkssf3hIsmHq/eFspiYsgMRMLQBwkBcpvJ6QlfdDA1Gf5+cvN0kWkUPLU+9 Tbpgw6Vsn/bZgHfqEad6Jk5WzKqmmfKdUKS6AsB8Pa4HAb0PXr20morXPy3OzuxGcB6U 3gA373xbTJyKieWniEHXCx1vf7LskqOWR6dA+XLtR3ZLW1IpzQVKs2DRNd3V4TcF0CEn etUnQJ3Rxw2IbwlrTkV8Ve8FCof60ApCASanNoqEmrcXxgblpjFWV+SVGAdU6ZsWoxhK mftA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1775726791; x=1776331591; 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=q9Nzk1LZvHLUlfOK8EzmGD671Kep8Lkhha7eumOX+U4=; b=X0r/dLPiCaRyAgu40DmcopfmsrwN21IQSRrFOSklFbPAylM1rY//FFNGwWw/Nad8uG AI0+7Rw61P5wx1d89wHzADEMMbGCXk4tSYf51o1tdg4Vae9f8llMaMbV/Ck4O3gwxBsi tPbfSHen1nkpIByvoyS1OzBPipkT7+OGyrapPV4nuTITolTSXDld5fYBt04k8NqsNEHt FXZnM2IS1496mXsJsJyoASUbt3bK+qy5p4Lb+q0bd2XSTgSp32+Kp8HmsHbqUZg4gWoB qsMDmdECmv69vVeJbwp7Bj1au+9NvDkl0pCC19i0ghVADKw1+zQTkM/ut5e+FguOt0eg Mefg== X-Forwarded-Encrypted: i=1; AJvYcCWQ3svj4DJ/TZ0eIJrArM29bjS4eRgHooze8uWzxsNbuTEaON/q/n/FFPh++TrmTaqebu6OmKr7ak0ed009@lists.postgresql.org X-Gm-Message-State: AOJu0YyKbt+nHdDcme13xtVH60upXrK7esFoeBQn5wBUy0V88NIKI1Pm eibj8+Gm7pYDvCY2uJZT6zR7nrUuDyF4rNZBp7btE+i4e8pqlCczOqdfHrphUQA245E= X-Gm-Gg: AeBDieuX9tLlTW8GQeX7tQrAldatxrvWrOCJaYd6g3Vr0bewIEENpm0s0qW6DV1Cjxm igUQuwAphrSeHyOsq4ycqUsB0EXLoQY685Vw76dQucwqEFVFmOZH2jVpQ4vQZXldul1qTCmDa5D 5LhwgeBaqiE9DFdEr8D/63G2bhSb4CxUP6Ecv1PBkMLkJ22xDqVNabKyDQFSfC7UGYeMymOIkhb o9+zaKbfh6GUJJH2LIbpv/iw0QxPBzBxVDsGcCPO2KmI16PG6Us1iNZacgN9eiBIzU7oktW4qLT oAvZVkEodVvRiZ3gO42htr8cvSugoQyGePkb52t54ArQEj89aGOXU5Gaf7pqClUugtUObwKtNKI V2GihAHbdTHlAHWtbKy2XUBRNJrEPADrB1iE6tvo08X9WBTngiRh7uej3+u6uavv1BJq7pwGOzT tiAlj7AqBkDgbG5I+ztuW2B2vqy5RXzCkKw7fs X-Received: by 2002:a05:600c:4743:b0:487:219e:42d with SMTP id 5b1f17b1804b1-4889970642emr334071295e9.11.1775726790728; Thu, 09 Apr 2026 02:26:30 -0700 (PDT) Received: from localhost (109-81-168-142.rct.o2.cz. [109.81.168.142]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-488cd23058dsm60480895e9.13.2026.04.09.02.26.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 09 Apr 2026 02:26:30 -0700 (PDT) From: Antonin Houska To: Mihail Nikalayeu cc: Amit Kapila , Andres Freund , Alvaro Herrera , Srinath Reddy Sadipiralla , Matthias van de Meent , Pg Hackers , Robert Treat Subject: Re: Adding REPACK [concurrently] In-reply-to: References: <202604062213.cgo352cdsgsm@alvherre.pgsql> <4n4q3preb3lgyhpzstebhux7b2aojhsw7gik4ivaznyggiezrs@lrznutssxlh2> <9539.1775724194@localhost> Comments: In-reply-to Mihail Nikalayeu message dated "Thu, 09 Apr 2026 11:11:16 +0200." 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: Thu, 09 Apr 2026 11:26:29 +0200 Message-ID: <10697.1775726789@localhost> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Mihail Nikalayeu wrote: > On Thu, Apr 9, 2026 at 10:43=E2=80=AFAM Antonin Houska w= rote: > > This approach LGTM when it comes to concurrent DDLs. However, consider = REPACK > > holding ShareUpdateExclusiveLock (SUEL) and VACUUM (w/o VACOPT_SKIP_LOC= KED) > > waiting for the same lock. Once REPACK releases its SUEL, VACUUM gets i= t and > > processes the table, then REPACK finally gets AccessExclusiveLock (AEL)= and > > finishes too. >=20 > > One more thing we may prevent from sneaking into that hole is a > > VACUUM. It will not break anything, but will be huge waste of time and > > resources. >=20 >=20 > I thought about that too, I think we may just add some kind of > CheckTableNotInUse in VACUUM after getting the SUEL. Sure, it's possible, but IMO the principal question is whether REPACK should let VACUUM and DDLs error out, or just let them wait. --=20 Antonin Houska Web: https://www.cybertec-postgresql.com