Subject | Performance: foreign keys, triggers.. |
---|---|
Author | Moreno Vandelli |
Post date | 2003-04-15T12:10:31Z |
Hi everybody,
[preface]
Recently I start working for an italian company using (the company) IB-6.01
(for more than 2 years now), and I would like "to port" their database in
FB-1.02. I deal with IB since 1998, I also worked with Ingres, PostgreSQL
and other minor rdbms.
This port will be more interesting for "my boss" if it can solve some leak
of the previous implementation.
The main application I deal with runs on about 20 clients for each of our
customers, on windows server.
Today, the database runs in dialect 1, it has 239 Tables, 57 View, 516
Procedure, 645 Triggers, 116 Generators, 23 Udf and its dimensions are 250MB
in gbk (there are also blob-jpgs inside).
The problem is that some recalculation like "articles-to-make",
"materials-needed-to-produce-articles" or "strore-recalculations" needs
something like 20 minutes each to be completed.
I trace the use of indexes and I found that there are no significant
"non-indexed-reads".
It is also true that for 2500 items in "ARTICLE" table we have to
recalculate a lot of stuffs, but no one of these is really "time expensive".
I realize a simple test comparison between ib6.01 windows and fb1.02 linux
and I think the second gain at least 20% in performance, but this is not
enough..
Since there are also some leak in the "logical project", I will be grateful
if you let me know your opinion about next themes:
[questions]
1) For "historical reasons" our database does not use foreign keys, so we
have to do everything "by hand" with triggers. Can the "no-use" of FK
decrease performance?
2) We take advantage of the "position" feature of the interbase-triggers.
There are differences, in performance, between a big trigger doing A+B+C
actions and 3 small triggers (in sequence) doing the same A+B+C actions?
3) Using a real three layer strategy (with an application server between
clients and fb database) to implement the same logic now realized in
so-called "slow-stored-procedure", can result in some performance
improvement?
4) Are there some tuning I can do to give to "ibserver.exe" more in-memory
resources (it is very "kind" with ram) ?
Thank you in advance,
Moreno Vandelli
PS: please forgive my poor english
[Non-text portions of this message have been removed]
[preface]
Recently I start working for an italian company using (the company) IB-6.01
(for more than 2 years now), and I would like "to port" their database in
FB-1.02. I deal with IB since 1998, I also worked with Ingres, PostgreSQL
and other minor rdbms.
This port will be more interesting for "my boss" if it can solve some leak
of the previous implementation.
The main application I deal with runs on about 20 clients for each of our
customers, on windows server.
Today, the database runs in dialect 1, it has 239 Tables, 57 View, 516
Procedure, 645 Triggers, 116 Generators, 23 Udf and its dimensions are 250MB
in gbk (there are also blob-jpgs inside).
The problem is that some recalculation like "articles-to-make",
"materials-needed-to-produce-articles" or "strore-recalculations" needs
something like 20 minutes each to be completed.
I trace the use of indexes and I found that there are no significant
"non-indexed-reads".
It is also true that for 2500 items in "ARTICLE" table we have to
recalculate a lot of stuffs, but no one of these is really "time expensive".
I realize a simple test comparison between ib6.01 windows and fb1.02 linux
and I think the second gain at least 20% in performance, but this is not
enough..
Since there are also some leak in the "logical project", I will be grateful
if you let me know your opinion about next themes:
[questions]
1) For "historical reasons" our database does not use foreign keys, so we
have to do everything "by hand" with triggers. Can the "no-use" of FK
decrease performance?
2) We take advantage of the "position" feature of the interbase-triggers.
There are differences, in performance, between a big trigger doing A+B+C
actions and 3 small triggers (in sequence) doing the same A+B+C actions?
3) Using a real three layer strategy (with an application server between
clients and fb database) to implement the same logic now realized in
so-called "slow-stored-procedure", can result in some performance
improvement?
4) Are there some tuning I can do to give to "ibserver.exe" more in-memory
resources (it is very "kind" with ram) ?
Thank you in advance,
Moreno Vandelli
PS: please forgive my poor english
[Non-text portions of this message have been removed]