crprashant commented on PR #2417: URL: https://github.com/apache/age/pull/2417#issuecomment-4654499481
Thanks for the careful review — both points addressed in the latest push (`85bca9f0`). **1. Rationale corrected.** You're right, the core-precedent claim was wrong — core keeps jsonb's `@>`/`<@`/`?`/`?|`/`?&` on `matchingsel`/`matchingjoinsel` on REL_16/17/18_STABLE. I reworded the **Why** (PR body), the comment block in `age--1.7.0--y.y.y.sql`, and the commit message to frame this as a deliberate planning-speed vs. estimate-accuracy trade-off that **diverges** from core, rather than a precedent restoration. I also fixed the contradictory **Notes for reviewers** line (dropped the inaccurate "core accepts the same trade-off for jsonb" / non-existent `jsonb_sel`) and added the one-line caveat that very-low-selectivity predicates may get worse estimates under `contsel`. **2. Upgrade-path assertion added.** `containment_selectivity.sql` now has an upgrade-path section that: - forces all 10 overloads back onto `matchingsel`/`matchingjoinsel` (simulating a stale pre-fix install) and asserts that state via `pg_operator`; - replays the exact `ALTER OPERATOR ... SET (RESTRICT, JOIN)` block the upgrade script ships; - asserts via `pg_operator` that every overload (both `oprrest` and `oprjoin`) flipped to `contsel`/`contjoinsel`. The whole section runs in a `BEGIN ... ROLLBACK` so it observes the flip without mutating catalog state for any later test. I replayed the shipped statements rather than running `ALTER EXTENSION age UPDATE` because the dev upgrade script targets the placeholder version `y.y.y` and isn't a stable version-chain target in the regress harness — there's a comment in the test explaining this. Expected output was regenerated by building + installing against PG18 and running `make installcheck REGRESS=containment_selectivity` (passes). -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
