Re: Parallel worker hangs while handling errors.
От | Bharath Rupireddy |
---|---|
Тема | Re: Parallel worker hangs while handling errors. |
Дата | |
Msg-id | CALj2ACVe+rPYUhxO45LfgYQYzjqERmPyh_uDvHvP4wje-dKWgQ@mail.gmail.com обсуждение исходный текст |
Ответ на | Parallel worker hangs while handling errors. (vignesh C <vignesh21@gmail.com>) |
Список | pgsql-hackers |
> > Parallel worker hangs while handling errors. > > When there is an error in the parallel worker process, we will call > ereport/elog with the error message. Worker will then jump from > errfinish to setjmp in StartBackgroundWorker function which was set > earlier. Then the worker process will then send the error message > through the shared memory to the leader process. Shared memory size is > ok 16K, if the error message is less than 16K it works fine. I reproduced the hang issue with the parallel copy patches[1]. The use case is as follows - one of the parallel workers tries to report error to the leader process and as part of the error context it also tries to send the entire row/tuple data(which is a lot more than 16KB). The fix provided here solves the above problem, i.e. no hang occurs, and the entire tuple/row data in the error from worker to leader gets transferred, see the attachment "testcase.text" for the output. Apart from that, I also executed the regression tests (make check and make check-world) on the patch, no issues are observed. [1] - https://www.postgresql.org/message-id/CALDaNm2-wMYO68vtDuuWO5h4FQCsfm4Pcg5XrzEPtRty1bEM7w%40mail.gmail.com With Regards, Bharath Rupireddy. EnterpriseDB: http://www.enterprisedb.com
Вложения
В списке pgsql-hackers по дате отправления: