Re: pgarchives: Bug report + Patches: loader can't handle message in multiple lists

Поиск
Список
Период
Сортировка
От Magnus Hagander
Тема Re: pgarchives: Bug report + Patches: loader can't handle message in multiple lists
Дата
Msg-id CABUevEy0vF9MLo0S_HPvwF8U=dZkM3Ob_QK_-X+=pN4e7uimJQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: pgarchives: Bug report + Patches: loader can't handle message in multiple lists  (Célestin Matte <celestin.matte@cmatte.me>)
Ответы Re: pgarchives: Bug report + Patches: loader can't handle message in multiple lists
Список pgsql-www
On Mon, Jun 5, 2023 at 3:39 PM Célestin Matte <celestin.matte@cmatte.me> wrote:
>
> > How does it even get that far?  The code on line 32 of storage.py will
> > check if the message is already in the archives. How does it even get
> > to the point of trying to insert the message again?
>
> Because my patch bypasses this by checking whether the message exists *in the given list*
>
> This was the beginning of an attempt to fix a crash I had. As far as I remember, the crash was that the message
alreadyexisted. 
>
> But as said in previous email, this was not sufficient to solve the issue.

OK, I think I need to take a step back to try to figure out what's
actually wrong here.

What is it you are actually trying to accomplish? Are you trying to
remove the single-store functionality for emails? As mentioned, the
whole design of the system is done around that a single email should
only be stored once - but it sounds like you're removing that for some
reason? Or am I misunderstanding?

It sounds to me like your patch that bypasses the check is either
broken or misguided, since that's what actually causes the problem?


> > I'm not sure I like the idea of committing after every message and
> > then rolling back in the event of an error. If nothing else, this
> > should be done using a savepoint instead of a complete transaction.
>
> Attached

--
 Magnus Hagander
 Me: https://www.hagander.net/
 Work: https://www.redpill-linpro.com/



В списке pgsql-www по дате отправления:

Предыдущее
От: Joe Conway
Дата:
Сообщение: Re: Need Editor Access
Следующее
От: Magnus Hagander
Дата:
Сообщение: Re: Regarding development of testcases for PGweb Testing Harness