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

babelfish-for-postgresql / babelfish_extensions / 13820962713
76%
BABEL_5_X_DEV: 77%

Build:
Build:
LAST BUILD BRANCH: fix-2998-4x
DEFAULT BRANCH: BABEL_5_X_DEV
Ran 12 Mar 2025 09:03PM UTC
Jobs 1
Files 115
Run time 2min
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

12 Mar 2025 08:31PM UTC coverage: 74.952% (-0.005%) from 74.957%
13820962713

push

github

web-flow
Alter procedure/function will unexpectly delete pg_depend records (#3572)

Backgroud:
In our previous implementation of the ALTER PROCEDURE/FUNCTION feature, we followed these steps to update metadata:

1. Create a new procedure/function
2. Replace the new OID with the old OID in the pg_proc metadata
3. Clean up pg_depend/pg_shdepend records referencing the new OID

Analysis: When creating a new procedure/function (step 1):

1. If the parameter list remains unchanged, the Create new function/procedure api will not insert new tuple but updating the existing tuple and return the old tuple oid. In this case, the old OID and new OID are identical, making the pg_depend records cleanup unnecessary.
2. If the parameter list changed, it missed to do anything about the pg_depend/pg_shdepend records created by the new ID, it'll leave inconsistent tuple in the pg_depend/pg_shdepend database.
The replacing of new OID (step 2) with the old OID is not necessary, since there's no other issues need to be concerned, and it's an over-design.

Fix:
For issue 1: Skip pg_depend records cleanup when old OID equals new OID.
For issue 2: Do not replace the new OID with the old OID, and just delete the pg_depend/pg_shdepend records referencing the old OID

Issue-resolved: BABEL-5601
Signed-off-by: Zhibai Song <szh@amazon.com>

11 of 11 new or added lines in 2 files covered. (100.0%)

2 existing lines in 1 file now uncovered.

47310 of 63120 relevant lines covered (74.95%)

188823.42 hits per line

Uncovered Existing Lines

Lines Coverage ∆ File
2
76.03
-0.63% contrib/babelfishpg_tds/src/backend/tds/tdscomm.c
Jobs
ID Job ID Ran Files Coverage
1 13820962713.1 12 Mar 2025 09:03PM UTC 115
74.95
GitHub Action Run
Source Files on build 13820962713
  • Tree
  • List 115
  • Changed 3
  • Source Changed 2
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #13820962713
  • 23066ed0 on github
  • Prev Build on BABEL_4_X_DEV (#13805235094)
  • Next Build on BABEL_4_X_DEV (#13853794548)
  • 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

© 2026 Coveralls, Inc