On Mon, Sep 11, 2017 at 1:49 AM, Fabien COELHO <coe...@cri.ensmp.fr> wrote:
> > Hello Jeff, > > Ok, the problem was a little bit more trivial than I thought. > > The issue is that under a low rate there may be no transaction in > progress, however the wait procedure was relying on select's timeout. If > nothing is active there is nothing to wait for, thus it was an active loop > in this case... > > I've introduced a usleep call in place of select for this particular case. > Hopefully this is portable. > Shouldn't we use pg_usleep to ensure portability? it is defined for front-end code. But it returns void, so the error check will have to be changed. I didn't see the problem before the commit I originally indicated , so I don't think it has to be back-patched to before v10. Cheers, Jeff