On Fri, Oct 6, 2017 at 3:07 PM, Ashutosh Bapat <ashutosh.ba...@enterprisedb.com> wrote: > On Fri, Oct 6, 2017 at 8:45 PM, Robert Haas <robertmh...@gmail.com> wrote: >> I think this is very good work and I'm excited about the feature. Now >> I'll wait to see whether the buildfarm, or Tom, yell at me for >> whatever problems this may still have... > > Buildfarm animal prion turned red. Before going into that failure, > good news is that the other animals are green. So the plans are > stable. > > prion runs the regression with -DRELCACHE_FORCE_RELEASE, which > destroys a relcache entry as soon as its reference count drops down to > 0. This destroys everything that's there in corresponding relcache > entry including partition key information and partition descriptor > information. find_partition_scheme() and set_relation_partition_info() > both assume that the relcache information will survive as long as the > relation lock is held. They do not copy the relevant partitioning > information but just copy the pointers. That assumption is wrong. > Because of -DRELCACHE_FORCE_RELEASE, as soon as refcount drops to > zero, the data in partition scheme and partition bounds goes invalid > and various checks to see if partition wise join is possible fail. > That causes partition_join test to fail on prion. But I think, the bug > could cause crash as well. > > The fix is to copy the relevant partitioning information from relcache > into PartitionSchemeData and RelOptInfo. Here's a quick patch with > that fix.
Committed. I hope that makes things less red rather than more, because I'm going to be AFK for a few hours anyway. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers