Re: BUG #1410: Hibernate PerformanceTest is incredibly slow

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: BUG #1410: Hibernate PerformanceTest is incredibly slow
Дата
Msg-id 10273.1106266828@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: BUG #1410: Hibernate PerformanceTest is incredibly slow  (Oliver Jowett <oliver@opencloud.com>)
Список pgsql-bugs
Oliver Jowett <oliver@opencloud.com> writes:
> If I patch Hibernate to not add a FK constraint at all, it runs
> substantially faster. It does not seem trivial to fix Hibernate to add
> an index in this case -- Hibernate wants to run "ALTER TABLE tablename
> <dialect specific sql>" to add a FK constraint, but we need to execute
> "ALTER TABLE tablename ADD CONSTRAINT ...; CREATE INDEX .... ON
> tablename ..." and the dialect code is not given "tablename".

> So to fix this properly needs some work on the Hibernate side.

That division of labor seems more than a tad brain-dead anyway;
who's to say that the appropriate dialect-specific command is an
ALTER TABLE at all?  It would be better if the dialect-specific
code were responsible for emitting the entire command --- in which
case it would have the tablename too and could do the Right Thing.

So I'd suggest filing a bug/enhancement request against Hibernate.

            regards, tom lane

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

Предыдущее
От: Oliver Jowett
Дата:
Сообщение: Re: BUG #1410: Hibernate PerformanceTest is incredibly slow
Следующее
От: "Jonathan Pool"
Дата:
Сообщение: BUG #1425: False failure message on boot start