Re: including backend ID in relpath of temp rels - updated patch
От | Tom Lane |
---|---|
Тема | Re: including backend ID in relpath of temp rels - updated patch |
Дата | |
Msg-id | 2299.1281636384@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | Re: including backend ID in relpath of temp rels - updated patch (Robert Haas <robertmhaas@gmail.com>) |
Ответы |
Re: including backend ID in relpath of temp rels - updated patch
|
Список | pgsql-hackers |
Robert Haas <robertmhaas@gmail.com> writes: > On Thu, Aug 12, 2010 at 12:27 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote: >> Lastly, it bothers me that you've put in code to delete files belonging >> to temp rels during crash restart, without any code to clean up their >> catalog entries. �This will therefore lead to dangling pg_class >> references, with uncertain but probably not very nice consequences. > I thought about this pretty carefully, and I don't believe that there > are any unpleasant consequences. The code that assigns relfilenode > numbers is pretty careful to check that the newly assigned value is > unused BOTH in pg_class and in the directory where the file will be > created, so there should be no danger of a number getting used over > again while the catalog entries remain. Also, the drop-object code > doesn't mind that the physical storage doesn't exist; it's perfectly > happy with that situation. Well, okay, but I'd suggest adding comments to the drop-table code pointing out that it is now NECESSARY for it to not complain if the file isn't there. This was never a design goal before, AFAIR --- the fact that it works like that is kind of accidental. I am also pretty sure that there used to be at least warning messages for that case, which we would now not want. regards, tom lane
В списке pgsql-hackers по дате отправления: