Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1Y3S8X-0005zi-Ub for pgsql-hackers@arkaria.postgresql.org; Tue, 23 Dec 2014 16:16:42 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1Y3S8X-0008ES-Bd for pgsql-hackers@arkaria.postgresql.org; Tue, 23 Dec 2014 16:16:41 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1Y3S8V-0008EM-VG for pgsql-hackers@postgresql.org; Tue, 23 Dec 2014 16:16:40 +0000 Received: from tamriel.snowman.net ([2001:4830:167b::11]) by makus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1Y3S8N-0005vY-Mi for pgsql-hackers@postgresql.org; Tue, 23 Dec 2014 16:16:37 +0000 Received: by tamriel.snowman.net (Postfix, from userid 1000) id 33FBC5F9F0; Tue, 23 Dec 2014 11:16:31 -0500 (EST) Date: Tue, 23 Dec 2014 11:16:31 -0500 From: Stephen Frost To: Robert Haas Cc: Tom Lane , Alvaro Herrera , "pgsql-hackers@postgresql.org" Subject: Re: [COMMITTERS] pgsql: Use a bitmask to represent role attributes Message-ID: <20141223161630.GG3062@tamriel.snowman.net> References: <31247.1419347882@sss.pgh.pa.us> <20141223153447.GD3062@tamriel.snowman.net> <31945.1419349892@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="vj77qGokqwYdeLil" Content-Disposition: inline In-Reply-To: X-Editor: Vim http://www.vim.org/ X-Info: http://www.snowman.net X-Operating-System: Linux/3.13.0-40-generic (x86_64) X-Uptime: 11:09:48 up 3 days, 19:49, 4 users, load average: 0.14, 0.23, 0.22 User-Agent: Mutt/1.5.21 (2010-09-15) X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org --vj77qGokqwYdeLil Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable * Robert Haas (robertmhaas@gmail.com) wrote: > On Tue, Dec 23, 2014 at 10:51 AM, Tom Lane wrote: > > Meh. To the extent that users look at pg_roles rather than pg_authid, > > it's going to look like another 15 boolean columns to them anyway ... > > except that now, those columns are suddenly a lot more expensive to rea= d. >=20 > Ugh. I think that's actually a really good point. I guess I'll +1 > reverting this, then. If that's the only consideration for this, well, that's certainly quite straight-forward to change in the other direction too. The new function suggested by Andres actually makes it really easy to get a textual list of all the role attributes which a role has from the bitmask too. I was more concerned with the on-disk and C-level structure and size than about the time required to get at the value of each bit at the SQL-level. Thanks, Stephen --vj77qGokqwYdeLil Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBAgAGBQJUmZVeAAoJEO1sijiDR2RVFioP/3JUp7gLxzDqSIEzKnnfgEI7 VmSKq1Bihcn6MP/vE6nWMqrMxIYE7IyQv9BamnjlcUt4CDOYQanfM0K565l09hAt VAc0DS20PhcLCDT7HT9A1rVnFN7IqgNekdJU9fOwSNg4UZTRECfMurFGOFsscGFK MByliB8pppF/IJ8geUTYj3N8bSazttd6F4HOyvYMmjeR60sRo43sUZPjvWTE2a6r 5ADUpWz+WwhrQ/sUFdvBkMlihDZjQg2LNA9n1R2zvwKcqaoHWFqYem1AQu6alVwJ AHHSzORS5W4h+IJcroH2BwrFlNhVt2Y1hyP/2tbkgZ3pbGpr+Ca+Gf3JAoYRmtZy sok3mMcRV6RiO8Q9LHePEImyigZ/dU+cJF1d2+WlRi6Cl0VlDW2XLnFKB1RAt810 w/GBIYljGZWrTdB6ApuIv6q6WRrCd8BbxOYu3viuq/ueepTMKdIaTqZm1ZA3eb2R 5uFu5Do/S6q8CPNlt3zqYiVGgxGhAdy0euQu3+S0LoDApqPQbPun4pODD6jMgqwE JR3C/m10EkZr5gwqWLqeMkDM0DpUApzHOxy9P0Hfen7KEyM75MggbwaMnMfyWHIU TSkRJS0hCAZLhywMK51XFYVGb3G4w2dF6kwI34i+jdGcZlWf/kLRQlVujmYU+BB8 t+1PduGCElSsp+4DKK4Y =CC9u -----END PGP SIGNATURE----- --vj77qGokqwYdeLil--