pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Michael Paquier <michael@paquier.xyz>
To: Jeff Davis <jdavis@postgresql.org>
Cc: pgsql-committers@lists.postgresql.org
Subject: Re: pgsql: Respect permissions within logical replication.
Date: Sat, 8 Jan 2022 18:25:17 +0900
Message-ID: <YdlYfS/l+PQA0ehs@paquier.xyz> (raw)
In-Reply-To: <Ydkfj5IsZg7mQR0g@paquier.xyz>
References: <E1n61f6-0006DS-Ek@gemulon.postgresql.org>
	<Ydkfj5IsZg7mQR0g@paquier.xyz>

On Sat, Jan 08, 2022 at 02:22:23PM +0900, Michael Paquier wrote:
> 2) crake fails perl-check
> https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=crake&dt=2022-01-08%2002%3A47%3A26
> 
> All the failures are the same, because of the shape of the subroutine
> definitions:
> Jan 07 21:53:04 ./src/test/subscription/t/027_nosuperuser.pl:
> Subroutine prototypes used at line 13, column 1.  See page 194 of
> PBP.  ([Subroutines::ProhibitSubroutinePrototypes] Severity: 5)

This issue is just caused by the way the subroutines are defined,
meaning that the attached cools down pgperlcritic.  Any objections if
I apply that to cool down crake?  Jeff, if you wish to do so, please
feel free of course.
--
Michael

Attachments:

crake-perlcritic.patch (text/x-diff, 2.0K) download diff --git a/src/test/subscription/t/027_nosuperuser.pl b/src/test/subscription/t/027_nosuperuser.pl index 742a745cf7..c9e4aeba06 100644 --- a/src/test/subscription/t/027_nosuperuser.pl +++ b/src/test/subscription/t/027_nosuperuser.pl @@ -10,7 +10,7 @@ use Test::More tests => 100; my ($node_publisher, $node_subscriber, $publisher_connstr, $result, $offset); $offset = 0; -sub publish_insert($$) +sub publish_insert { my ($tbl, $new_i) = @_; $node_publisher->safe_psql('postgres', qq( @@ -19,7 +19,7 @@ sub publish_insert($$) )); } -sub publish_update($$$) +sub publish_update { my ($tbl, $old_i, $new_i) = @_; $node_publisher->safe_psql('postgres', qq( @@ -28,7 +28,7 @@ sub publish_update($$$) )); } -sub publish_delete($$) +sub publish_delete { my ($tbl, $old_i) = @_; $node_publisher->safe_psql('postgres', qq( @@ -37,7 +37,7 @@ sub publish_delete($$) )); } -sub expect_replication($$$$$) +sub expect_replication { my ($tbl, $cnt, $min, $max, $testname) = @_; $node_publisher->wait_for_catchup('admin_sub'); @@ -46,7 +46,7 @@ sub expect_replication($$$$$) is ($result, "$cnt|$min|$max", $testname); } -sub expect_failure($$$$$$) +sub expect_failure { my ($tbl, $cnt, $min, $max, $re, $testname) = @_; $offset = $node_subscriber->wait_for_log($re, $offset); @@ -55,28 +55,28 @@ sub expect_failure($$$$$$) is ($result, "$cnt|$min|$max", $testname); } -sub revoke_superuser($) +sub revoke_superuser { my ($role) = @_; $node_subscriber->safe_psql('postgres', qq( ALTER ROLE $role NOSUPERUSER)); } -sub grant_superuser($) +sub grant_superuser { my ($role) = @_; $node_subscriber->safe_psql('postgres', qq( ALTER ROLE $role SUPERUSER)); } -sub revoke_bypassrls($) +sub revoke_bypassrls { my ($role) = @_; $node_subscriber->safe_psql('postgres', qq( ALTER ROLE $role NOBYPASSRLS)); } -sub grant_bypassrls($) +sub grant_bypassrls { my ($role) = @_; $node_subscriber->safe_psql('postgres', qq(
signature.asc (application/pgp-signature, 832B) download

view thread (7+ messages)  latest in thread

Message-ID: <YdlYfS/l+PQA0ehs@paquier.xyz>
Permalink:  ../YdlYfS%2Fl+PQA0ehs@paquier.xyz/
Also on:    postgresql.org/message-id/YdlYfS/l+PQA0ehs@paquier.xyz

 ·  · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: michael@paquier.xyz, jdavis@postgresql.org
  Subject: Re: pgsql: Respect permissions within logical replication.
  In-Reply-To: <YdlYfS/l+PQA0ehs@paquier.xyz>
  References: <E1n61f6-0006DS-Ek@gemulon.postgresql.org> <Ydkfj5IsZg7mQR0g@paquier.xyz> <YdlYfS/l+PQA0ehs@paquier.xyz>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox