Re: How is this possible "publication does not exist"

From: operations i <ioperations(dot)c(at)gmail(dot)com>
To: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>
Cc: PostgreSQL Bugs <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: How is this possible "publication does not exist"
Date: 2022-06-02 11:00:40
Message-ID: CANWRaJx=8wbORaBsiTxvxh6fUmi2WDDRZeWFF3FhJKw7pkUGkA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-general

after several times debugging, I 've realized the key point is the order of
publication creation and insert statement, and both two have reached
catcache.c:SearchCatCacheMiss() .and below has the difference explained
1. publication create first and then insert data into table
the expression ```HeapTupleIsValid(ntp =
systable_getnext(scandesc))``` return true

2.insert data into table and then create publication
the expression ```HeapTupleIsValid(ntp =
systable_getnext(scandesc))``` return false

so in case 2 , when decoding the first change , system table snapshot do
not have Publication 'pub_test' , so throw the error
" publication 'pub_test'" not exists

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message operations i 2022-06-02 11:01:03 Re: How is this possible "publication does not exist"
Previous Message Shaheed Haque 2022-06-02 10:27:26 Unable to make use of "deep" JSONB index

Browse pgsql-general by date

  From Date Subject
Next Message operations i 2022-06-02 11:01:03 Re: How is this possible "publication does not exist"
Previous Message Tim Kelly 2022-06-02 10:52:18 Re: unoptimized nested loops