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 1vylfe-000P2l-2i for pgsql-hackers@arkaria.postgresql.org; Sat, 07 Mar 2026 07:01:54 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1vylfa-007zbZ-2Z for pgsql-hackers@arkaria.postgresql.org; Sat, 07 Mar 2026 07:01:51 +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 1vylfa-007zbR-17 for pgsql-hackers@lists.postgresql.org; Sat, 07 Mar 2026 07:01:50 +0000 Received: from mail-lj1-x22e.google.com ([2a00:1450:4864:20::22e]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1vylfY-00000000xvv-2jVT for pgsql-hackers@postgresql.org; Sat, 07 Mar 2026 07:01:49 +0000 Received: by mail-lj1-x22e.google.com with SMTP id 38308e7fff4ca-38a42a0d7f7so8410381fa.1 for ; Fri, 06 Mar 2026 23:01:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1772866907; cv=none; d=google.com; s=arc-20240605; b=FkDqVI0v23Ac6P7sbQU9M0Yz7cYDMbvqS5qdmjJL37MTbWp3fSJgXIKQ2eus1oKYDs hkV834xMGl6vRWOrI70S3h9F/+GB+6e8BIiaReoZr7AOEjvFO7r0DwGTNiQWs+v7TaDq +YtCyYK8utpmpJ/6wG+ec3+jUA3L1UUObCiX5/86K/fUpPQgKbnKfj8WWNlaqGmJRIBZ GxKgDETRLhw9TiRVM1IiOYPHgOKUgfEVooDIQo6r4YUMKmVameMVX6CTBpS1FFhiPbrm X+K8EFKNCP8tGUGtkqmLRhslSdSJS4zJ+ahTSkM/Yynb2UiHiEdkyGE0dGewGWJtskj8 BwSQ== 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=SnNTKKj84VjNSQ+W5kMrSSyeA6Y2rWCDGTqptbuAKyQ=; fh=Kaito5+okGPLebmcF1C8bzpdMW8PPve2nmtH8ieyaJo=; b=DUw5IvOAe6oHYLKvuakJjb9F5ueJsMSFcC541qLNui02Vb4iT7DsknxrwHjYU1ARqr U1q344p+RfU1ICbUds7KwXLKruBguWSnqEe2qfL0O8MCpiDtWhEj+hJLykXomzn/zj5B 84EOFbquTQNUbPrUsR6zCbLOLt3SwD3H5k7tQeCcVmuR5lBG15x4ycZm7ST6jWHcDjNs kvP6EcwqiJhWiAyqsbUohTKsk5W6Udcd+yNR58DGCqrD95T3iY3tRj1OyMZ1ZJW+L7z7 4WlhwGfdstS186U6R76McA2ywBKeSi3JukCS1PK8z07eTlwnWBGt1OLRewUa5bA2gGen P1aQ==; 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=1772866907; x=1773471707; 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=SnNTKKj84VjNSQ+W5kMrSSyeA6Y2rWCDGTqptbuAKyQ=; b=Lnzir6XbIjd2WgeTgSMx5M2J5ngDKA1BCRSZwi5r4ivbwOKbn6Udw2tstzFA83vxCR c8RfH++KqsVgOobx6jUOU+hOcmjGB4yP/yvVY6sbuBkHHYdXuBETSLpB8d60oqY0mh0A hR6jakeZQrDNF2Qxm/UmD0RzI6fM2rqG2+I+O3+hABjL4yR5nmiq0AS7vgnNFWG71rKx OH84xN4U6yyAJYp6kZlLEJsCYmwTXsCGOc9S8H2Cp3GfzyWUeaWXbSfjIuPDgkYArKfg ys8E1mcbK/caBpr9wXC6prik9sfm3eNLR+hcJfinzqESMAOAzAGYC/BmikhEJUsOWLQn jqYg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772866907; x=1773471707; 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=SnNTKKj84VjNSQ+W5kMrSSyeA6Y2rWCDGTqptbuAKyQ=; b=TaQRq3lyvJl7A9bO9OJgjJT9vpzTSfq9rOKeug9EWNZletSbkVTh8z6rsn+/ZCag4L NmAh8H8WhLZKVl6nJm878coAYs+z/Flps/IFlkdt0I2mEmLE714IcFdzQDFNQ6i9qVRR ZdxRt312NDaY9NuVdYPq5fN7qXEWBFirUrRlVYrmCHG/BiW5kIAlQV0uM+p+TAk0LARx XYPrXLnchb/h5gsCRw9exR6Mvm3hO6tiykB4gI1K9shk4OExnrkFibiZLBQo40JHNDcE 9N7tk2AVmZDYk1Jw9TKAgxgRu1X8SW6rcy+rRLG4vIswTUduvaHzSlOxXODz48KC7vYw 0oXA== X-Forwarded-Encrypted: i=1; AJvYcCW23sUex0CxI5ZPokoJK7pq8ROXYe/cAJfH3dNqQRZD0fBZDiEUByfWysMRhTE99LrrRwpdEBey9oUAR/SM@postgresql.org X-Gm-Message-State: AOJu0YyDWbingqHnClOn80vRn2I/i7o+BPAmgoQsgdnzWg16/b+TvNw5 YhHr7JxME5noAX+LSVFPOBnHxQ79M1TFJmAZtalumrceUhnpIGO3TLHiBumfv9slYupwUBpyF8E swe1VozonwT8Ks2XZ3eBDgmRQ6hwJ+ds= X-Gm-Gg: ATEYQzyenAQ+MXtKoOcT1f0N2iQf9ITnitFCDUOUDBq5obisR//OJBR0Br6A36bViY/ 0a7ejzSGdwpgwTw3L323FHtMSKcli6yXG+tSNV4t/6Ss+VrCKXtId0m1ZGuH5gaFuu3LfYE/UZ0 QlqCXdWyyqqfuGHmdbY/DCItFhrqVdAADHsefhKF80UaJjmnrsGggPuL+LVPYMbjnVBkijQNkNv 1VHlWDLUsXvD7NcBpBtfqLu0yBJDEBrxE9Jip4pk3g3vk2WY18qQBgl0GB+bg3KSVwpSzpS/HIS Y3ORzWFJC3QtUEtGjNmf9Plx8EXWUR8+y2U51fYC X-Received: by 2002:ac2:5b43:0:b0:5a1:348e:c37 with SMTP id 2adb3069b0e04-5a1348e0d95mr1879676e87.24.1772866906644; Fri, 06 Mar 2026 23:01:46 -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: <80303af653a3da2a94e32ff91d6538675e921bf0.camel@j-davis.com> From: Amit Kapila Date: Sat, 7 Mar 2026 12:31:35 +0530 X-Gm-Features: AaiRm52Z3LEmKJc0sv7kVa_CfahA6NALinvGeFwGXK5Ub8vYwNUzAXlQjUtKs08 Message-ID: Subject: Re: [19] CREATE SUBSCRIPTION ... SERVER To: Jeff Davis Cc: Masahiko Sawada , Shlok Kyal , Ashutosh Bapat , 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 Thu, Mar 5, 2026 at 2:23=E2=80=AFPM Jeff Davis 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 also can't think of any straight-forward solution for it. I've not thought in detail but can a new type of dependency be required to solve this problem? I am not aware if we are doing something similar in any other CASCADE operation, so even if we want to go with giving ERROR for this case, it may be better to get somewhat wider acceptance for the same unless few other people respond here and consider this as an acceptable solution. Few other minor comments: =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D 1. +# Replicate the changes without columns +$node_publisher->safe_psql('postgres', "CREATE TABLE tab_no_col()"); +$node_publisher->safe_psql('postgres', + "INSERT INTO tab_no_col default VALUES"); I don't see a subscriber-side table or verification code to verify the above test. 2. + Oid subserver BKI_LOOKUP_OPT(pg_foreign_server); /* If connection uses + * server */ + Isn't it better to keep this along with other oids in the beginning of the catalog, say after subowner? It will also avoid padding before subserver field. --=20 With Regards, Amit Kapila.