On Mon, Nov 12, 2018 at 11:55 PM Jeremy Finzel <finz...@gmail.com> wrote:
>
> I believe I found a race condition in WaitForBackgroundWorkerStartup in the 
> case where it encounters an ERROR during startup.  I found that depending on 
> the speed of the system, it will unreliably return either status BGWH_STOPPED 
> or BGWH_STARTED.  But I can reliably reproduce getting BGWH_STOPPED by 
> tweaking the worker_spi.c test module.
>

Yeah, I think it is possible that you get different values in such
cases because we consider worker status as started after we have
launched the worker.  Now, if we get the error in the worker
initialization, then the user can get any of those values.  I think
this is what is happening in your case where you are saying "ERROR
during startup".
Am I missing something?

-- 
With Regards,
Amit Kapila.
EnterpriseDB: http://www.enterprisedb.com

Reply via email to