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 1vyljS-000P6x-0a for pgsql-hackers@arkaria.postgresql.org; Sat, 07 Mar 2026 07:05:50 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1vyljQ-0081Zy-1c for pgsql-hackers@arkaria.postgresql.org; Sat, 07 Mar 2026 07:05:48 +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 1vyljQ-0081Zp-0I for pgsql-hackers@lists.postgresql.org; Sat, 07 Mar 2026 07:05:48 +0000 Received: from mail-lj1-x232.google.com ([2a00:1450:4864:20::232]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1vyljO-00000000xxp-3HsV for pgsql-hackers@postgresql.org; Sat, 07 Mar 2026 07:05:47 +0000 Received: by mail-lj1-x232.google.com with SMTP id 38308e7fff4ca-38a3f6da741so12008561fa.1 for ; Fri, 06 Mar 2026 23:05:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1772867145; cv=none; d=google.com; s=arc-20240605; b=ZhvcDoBW3+v3Nmp4E0cPZkooOGG1DtDZGGI61lkTUna1iBQefkbVQsk3IIhojzKJYy jOI7JSpD3nddTAcR2ahHhrQ1iq+bbHWI5LUrsAAHnqxAm1yzgXFYm8gjVXLBeK/lpzxX RtxNmdwy5jyFbuJSPBMl2w25x/URvzVTjauK9wc7KloYHq11s+RbF51HvtptggySdIev c9wNFePmRo8dv13pJ4QlA5hFqiVApHcJyOPer1XdR4AihJdJZ2dH8Aw0G1d+tdM32xlx yCtgwAPXg1wZfFIjPN8r3srEJGP7Un1K4o1qM542zhUm9iyaEH7XFt1oCUEEZk2L7glU oNSQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=OPBaeqkKLPYyeGfr70mC2x2G8Y3fSfywDNIVj96RImc=; fh=CqdRY+DdPBkS1R5DzkV1mrL5EmdiA8SXgGFQ+uVdpeg=; b=ewNB70rYuKL902WLGsH94Tinm27p8L29RKrwQLWNReyEkXfJpJNPySdjelK/JZeqif 66jmRCm0DoYW9ODD4IBZlng/ZWl2QqB+bjfJMChztZbcMYs4gQpDT4gco1jsBrHrCX9U IwhJ6Q+J3o3O5+XnYhiO903WmT1AMTo9/U1PftTQZj3pLNoUlF5vBikRHf/g/wIzhJiE rlkibbUfqJk08Cfa47WyXDH1qtnxJq4QQSTT40k+r3cJR1CQhkK98julkm+bKaAkj0Mj 3Xr6zTMtzCxIJvQ/qEb3w8pOFga/xAMAhW97CWaKxrfeFhOdKMmwd2kA5MpC5JPrhIYk 92JQ==; darn=postgresql.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1772867145; x=1773471945; darn=postgresql.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=OPBaeqkKLPYyeGfr70mC2x2G8Y3fSfywDNIVj96RImc=; b=fNxcdoKYgCGS3TZo7/lUW1NnVVbe198pNXj3VOcbW40sBHFkBcIa+/uPxJP32VEifo KyFtWujtKM8tMs2iRE4dCGssIXLZ0CPKqKtUqmHgD4wSojnXW89dU3EhoX95ROh82B5d ug+ZHahn0X92JPbdS2PNGeJ6DhzQo9FU56ieZ+etntdAiXGObGfGLh+XUFmCHhPrLIx8 lrQ3+ULgqE+mV8IFguU1m2kJlZ6c0cLTTchxaTvXI8lbTvTc2tnasyNuUIMsB+lj5xIi ZqyFSRniqzwAmTFOBiAK1h/KUf7Fl/PTr2OfOhgCZcDy75hoqldCLUC70ATkPLFbbaI+ KE8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772867145; x=1773471945; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=OPBaeqkKLPYyeGfr70mC2x2G8Y3fSfywDNIVj96RImc=; b=JqV2D9DKagpnAt1f5MDOQseVl3JK9DnegD4uMw2gAzIhZYUtxK4+MwESSIdFFaixNZ /I3smhGqH9OYp5gbeBBK+Mk1vO1EOeyF56d62uglGWPSdnNOAREfQhRPeyct7P66G+40 ja1Q/d7ac1FFGvsinlbtAnDsHid02KvabPYw3fMdWBgtKQ9yNTMr2/lAk7bzRke3wWgQ kUs68rP9IU/nRwO3RcEIpO3L+VrKzNaDA2S8inaNUl3IqonTwFT7bBbE20hQbJy6IAsr e85dPdoR++jd0yJjBvxLNLocV8UtB25Mc3kgF5lZMEa6YRpJXzJiIPwPVtu0v2hIQQjA aIrg== X-Forwarded-Encrypted: i=1; AJvYcCW1BFjRHKFAcheXJkbeYlbX7lAoUX4m+jMGflko2gRIcQhn8anGjMRTuvaidbt+DkExJauNraTy5lqx46o1@postgresql.org X-Gm-Message-State: AOJu0YyGR7vFYe8nsMY9vblI4lkq9ouIm1KWmq168MELcKOAwUqKVxMD 7Smz8Q9eJLJ+pcaTm9+Risl/aYcHX7+ZjnojJJwIsBev/RAOGrHkA5NidV74cExblnA7sR9E3au NhDeUyeiEAO+5Fz+tMijBf9ccEqPqEBI= X-Gm-Gg: ATEYQzy0LrnwF8HGrRPF3HNXOIpDVN1Mg8sxP3fdioq6s6Q3rWDxMMaEBtxxAmwFQke JyrFkCUZHE1anTsR7E4hIrQH39a+v9tupCp7lIWskFdmrPIjsYeg9qr21ty1+DzTRB4VXp9qWZ1 QHwwUZhC7W3bekhFK+sxLSVZt/RYsgNisQ+Tn2c/JGObbrIySoo1kAgI7ilUu5WvjmV54Q0cXZR r9BNIW4DcDDG3rOe7fKQKOwlDNpiChvbl4d8sr3Kjd1YL4EPalQLNYywKNHWQxn3e8Fq9N76mHy tcs8XDMGVcxqUnfeuBckhivMiis0TsYjziJE6iGX X-Received: by 2002:a05:651c:987:b0:383:1994:8d with SMTP id 38308e7fff4ca-38a40d81935mr13235691fa.40.1772867144368; Fri, 06 Mar 2026 23:05:44 -0800 (PST) MIME-Version: 1.0 References: <149ff9264db27cdf724b65709fbbaee4bf316835.camel@j-davis.com> <830a2bc6cbbb2e6e01c6c0d9f31f320822e10603.camel@j-davis.com> <433d0845248e86c0317d9d396926182cfe157340.camel@j-davis.com> <05ae37abb207cd6bf6b126780024692d91402b0b.camel@j-davis.com> <93392ffa941ab0d436e19e0ab5d04d0e42c02d3f.camel@j-davis.com> <26be917cb07b6aa3ef5dd15f6b59d1b375ece6e8.camel@j-davis.com> <55201bd916e748acfc754c8f95880dae8e4e5ed0.camel@j-davis.com> <2a89b14a2b1622bffb8b137ca1f9ab7866f2d2b9.camel@j-davis.com> <61831790a0a937038f78ce09f8dd4cef7de7456a.camel@j-davis.com> <0910b47040406c1d24ec0150dafb5bae6b910ed7.camel@j-davis.com> <7338f22c4534322a08ab6ce9f879e2e308eb5e5d.camel@j-davis.com> <34fd5885b8245d1014f4426ea22af61229d42e3e.camel@j-davis.com> <7a5df376fffb273430aec9e89f88c31d52dcf295.camel@j-davis.com> <5dfe845221db2e7d38fc7c2a18a4ba5ea29cdfc0.camel@j-davis.com> <60ff024706fe1beab62a89ac07eb6a721856de2e.camel@j-davis.com> <80303af653a3da2a94e32ff91d6538675e921bf0.camel@j-davis.com> In-Reply-To: From: Amit Kapila Date: Sat, 7 Mar 2026 12:35:32 +0530 X-Gm-Features: AaiRm50B9U3uP1zq3Z5_h1gr6vENL6WYC7a_4Cf27kYYtPlqrRse0OyNVrZtubY Message-ID: Subject: Re: [19] CREATE SUBSCRIPTION ... SERVER To: Ashutosh Bapat Cc: Jeff Davis , Masahiko Sawada , Shlok Kyal , Bharath Rupireddy , Joe Conway , pgsql-hackers@postgresql.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Fri, Mar 6, 2026 at 9:49=E2=80=AFPM Ashutosh Bapat wrote: > > On Thu, Mar 5, 2026 at 2:23=E2=80=AFPM Jeff Davis wro= te: > > > > On Thu, 2026-03-05 at 09:21 +0530, Amit Kapila wrote: > > > > Additionally, I ran into a problem that's worth highlighting: > > > > DROP SERVER ... CASCADE was broken, because the subscription is > > dependent on it but that's in a global catalog, which is not handled by > > doDeletion(). The subscription is conceptually a per-database object, > > but it's in a shared catalog with a subdbid field. I solved that > > problem by adding a guard to findDependentObjects() to check for the > > referenced object belonging to a shared catalog, and if so it just > > throws an error (so CASCADE is not supported for servers used in > > subscriptions). That's a simple but not a very satisfying solution, so > > let me know if you see a problem with that. > > I shared the awkwardness, but don't have any better ideas. However, it > does raise a question as to why do we need an FDW to be database > specific or for that matter a SERVER database specific. That might be > because it requires an extension which is database specific. Probably > we should support extensions which are database agnostic. However > that's way beyond the scope of this patch. Other way around why do we > need subscriptions to be shared objects? > It is because the launcher process needs to traverse all subscriptions to start workers. --=20 With Regards, Amit Kapila.