Skip to content

2.25.2.0-b203

@myang2021 myang2021 tagged this 21 Mar 01:59
Summary:
This diff changes the current `TEST_yb_enable_invalidation_messages` to
a preview gflag `ysql_yb_enable_invalidation_messages`. Also changed
`TEST_yb_invalidation_message_expiration_secs` to
`ysql_yb_invalidation_message_expiration_secs` and
`TEST_yb_max_num_invalidation_messages` to `ysql_yb_max_num_invalidation_messages`.

These gflags are all PG runtime gflag.  The curreng PG runtime gflag framework requires
them to also become PG GUCs. For example,

```
DEFINE_RUNTIME_PG_PREVIEW_FLAG(bool, yb_enable_invalidation_messages, false,
    "True to enable invalidation messages");
```

This introduces a gflag `--ysql_yb_max_num_invalidation_messages` and a PG GUC
variable called `yb_max_num_invalidation_messages`. The gflag is used by
yb-tserver and yb-master, while the GUC is used inside PG code.

These gflags are safe to change at runtime. If master is old release and tserver is
new release, then master will not read `pg_yb_invalidation_messages` to populate
the heartbeat response message. In that case tserver will not find any
invalidation messages so it will only update catalog versions. If tserver is old
release and master is new release, then master will read
`pg_yb_invalidation_messages` and that will be ignored by tserver, which will
not have any of its PG backends write anything to `pg_yb_invalidation_messages`.

Test Plan: ./yb_build.sh --cxx-test pg_catalog_version-test

Reviewers: kfranz, sanketh, mihnea

Reviewed By: kfranz

Subscribers: jason, yql

Differential Revision: https://phorge.dev.yugabyte.com/D42668
Assets 2
Loading