• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

babelfish-for-postgresql / babelfish_extensions / 14405600972
74%
BABEL_5_X_DEV: 77%

Build:
Build:
LAST BUILD BRANCH: BABEL-5844-4x
DEFAULT BRANCH: BABEL_5_X_DEV
Ran 11 Apr 2025 03:06PM UTC
Jobs 1
Files 115
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

11 Apr 2025 02:35PM UTC coverage: 74.015% (-0.001%) from 74.016%
14405600972

push

github

web-flow
Avoid checking permission of Babelfish temp tables on parallel worker (#3673)

Consider following facts,

Babelfish temp tables are implemented using ENR which is not shared between different backends. So if Parallel worker tries to check permissions on Babelfish then it will fail.
Any user should be able to access Babelfish temp tables under given session.
Postgres by default does not allow parallel operations on temp tables. Attempt to do so will result in run time error.
Due to above facts, we should avoid permission check on temp tables within parallel workers while ensuring that leader does required permission check on other tables. This commits achieves this behaviour by implementating following three hooks,

bbf_ParallelQueryMain_hook -- implements ParallelQueryMain_hook. It constructs Bitmapset (list of temp table oids) by looping through es_range_table checking if given relation is temp table, checks permission if it is and add it to the set. It will then pass this set of temp table defined under current with Parallel workers.

bbf_ExecInitParallelPlan -- implements ExecInitParallelPlan_hook. Parallel workers will gather additional details (oid set of temp table) passed by Leader node. This set will later be used to avoid checking permissions on temp tables.

bbf_ ExecCheckRTEPerms_hook -- implements ExecCheckOneRelPerms_hook. It will avoid permission check relation if relid is part of the set of oids constructed using bbf_ExecInitParallelPlan.

Task: BABEL-5703
Signed-off-by: Dipesh Dhameliya <dddhamel@amazon.com>

33 of 48 new or added lines in 2 files covered. (68.75%)

1 existing line in 1 file now uncovered.

43768 of 59134 relevant lines covered (74.01%)

182792.39 hits per line

New Missed Lines in Diff

Lines Coverage ∆ File
3
83.49
-0.08% contrib/babelfishpg_tsql/src/hooks.c
12
70.0
contrib/babelfishpg_tsql/src/bbf_parallel_query.c

Uncovered Existing Lines

Lines Coverage ∆ File
1
83.49
-0.08% contrib/babelfishpg_tsql/src/hooks.c
Jobs
ID Job ID Ran Files Coverage
1 14405600972.1 11 Apr 2025 03:06PM UTC 115
74.01
GitHub Action Run
Source Files on build 14405600972
  • Tree
  • List 115
  • Changed 3
  • Source Changed 2
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #14405600972
  • 3ddff85c on github
  • Prev Build on BABEL_3_X_DEV (#14261030212)
  • Next Build on BABEL_3_X_DEV (#14453632787)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc