On Thu, Nov 15, 2018 at 5:09 AM Dmitry Dolgov <9erthali...@gmail.com> wrote: > While testing this patch with frequent checkpoints I've stumbled upon an > interesting error, that happened already after I finished one test: > > TRAP: FailedAssertion("!(rc > 0)", File: "checkpointer.c", Line: 574)
Thanks for testing! Yeah, that's: + rc = WaitEventSetWait(wes, cur_timeout * 1000, &event, 1, 0); + Assert(rc > 0); I got confused about the API. If there is a timeout, you get rc == 0, but I think I was expecting rc == 1, event.event == WL_TIMEOUT. Oops. I will fix that when I post a new experimental version that uses the bgworker as discussed, and we can try to figure out if that design will fly. -- Thomas Munro http://www.enterprisedb.com