Re: Avoid useless retrieval of defaults and check constraints in pg_dump -a
| От | Daniel Gustafsson | 
|---|---|
| Тема | Re: Avoid useless retrieval of defaults and check constraints in pg_dump -a | 
| Дата | |
| Msg-id | 65BBC477-AAEF-4356-B7D5-C41624EE5330@yesql.se обсуждение исходный текст  | 
		
| Ответ на | Avoid useless retrieval of defaults and check constraints in pg_dump -a (Julien Rouhaud <rjuju123@gmail.com>) | 
| Ответы | 
                	
            		Re: Avoid useless retrieval of defaults and check constraints in pg_dump -a
            		
            		 | 
		
| Список | pgsql-hackers | 
> On 12 Jul 2020, at 07:48, Julien Rouhaud <rjuju123@gmail.com> wrote: > Currently, getTableAttrs() always retrieves info about columns defaults and > check constraints, while this will never be used if --data-only option if used. > This seems like a waste of resources, so here's a patch to skip those parts > when the DDL won't be generated. Given how unintrusive this optimization is, +1 from me to go ahead with this patch. pg_dump tests pass. Personally I would've updated the nearby comments to reflect why the check for dataOnly is there, but MMV there. I'm moving this patch to Ready for Committer. I'm fairly sure there is a lot more we can do to improve the performance of data-only dumps, but this nicely chips away at the problem. cheers ./daniel
В списке pgsql-hackers по дате отправления: