Subject | excessive network traffic [LONG] |
---|---|
Author | Art Metz |
Post date | 2001-01-24T23:17:23Z |
I am seeing what appears to be excessively many packets going between client
and server. Details follow.
I'm supporting a legacy app written with Delphi 3, BDE, InterBase 5.6. It
needs to query a database created by a different app. It connects to a
remote database over a modem using TCP/IP.
For various reasons, different versions of App2 have different database
schemas. App1 must support all the different versions. So, after opening
the database, App1 queries some system tables to determine if certain fields
and tables are present.
The problem that I'm having is that the connection over a 56k modem is
noticeably s-l-o-w. One of the network guys put a sniffer on the connection
to determine just what the traffic was. Here are some examples of the
dialog. I'm not bothering to uppercase names in literals.
1. // does a certain field exist?
select rdb$field_name, rdb$relation_name from rdb$relations
where (rdb$field_name = 'archive_24')
and (rdb$relation_name = 'alarminfo')
returns 1518+1518+1246+150 (=5950) bytes
2. // a query on a single-row table
select realsite_id from alarminfo
returns 1518+1518+1246 (=5800) bytes
3. // does a certain table exist?
select * from rdb$relations where
rdb$relation_name = 'mon1_camera'
returns 1518+1518+1246 (=5800) bytes
4. // Is this query generated by the BDE?
select rdb$owner_name, rdb$relation_name, rdb$system_flag,
rdb$view_blr, rdb$relation_id from rdb$relations
where rdb$relation_name = 'alarminfo'
returns 1518+1518+1518+1246+170+
1518+1518+1518+1246+
1518+1518+1518+1450
(=17774) bytes
The "stuttering" of the value 1518 makes me wonder if the BDE (or possibly
gds32) is attempting a query; timing out; and then re-sending. OTOH, the
client doesn't resend. Could the server be looking for an ACK and
re-sending if one doesn't come through?
5. I have other queries (you know, the kind that actually gets data to
work with) that get sent up to four times in succession. This looks to be a
true timeout/resend sequence.
My point (and I do have one!) and questions are:
a. This traffic seems excessive. Do you agree?
b. Where does it originate: bde? gds32? tcp/ip?
c. Would I get less traffic if I switched to IBObjects?
d. How can I reduce it?
Any suggestions or pointers will be greatly appreciated.
Art Metz
AMetz@...
and server. Details follow.
I'm supporting a legacy app written with Delphi 3, BDE, InterBase 5.6. It
needs to query a database created by a different app. It connects to a
remote database over a modem using TCP/IP.
For various reasons, different versions of App2 have different database
schemas. App1 must support all the different versions. So, after opening
the database, App1 queries some system tables to determine if certain fields
and tables are present.
The problem that I'm having is that the connection over a 56k modem is
noticeably s-l-o-w. One of the network guys put a sniffer on the connection
to determine just what the traffic was. Here are some examples of the
dialog. I'm not bothering to uppercase names in literals.
1. // does a certain field exist?
select rdb$field_name, rdb$relation_name from rdb$relations
where (rdb$field_name = 'archive_24')
and (rdb$relation_name = 'alarminfo')
returns 1518+1518+1246+150 (=5950) bytes
2. // a query on a single-row table
select realsite_id from alarminfo
returns 1518+1518+1246 (=5800) bytes
3. // does a certain table exist?
select * from rdb$relations where
rdb$relation_name = 'mon1_camera'
returns 1518+1518+1246 (=5800) bytes
4. // Is this query generated by the BDE?
select rdb$owner_name, rdb$relation_name, rdb$system_flag,
rdb$view_blr, rdb$relation_id from rdb$relations
where rdb$relation_name = 'alarminfo'
returns 1518+1518+1518+1246+170+
1518+1518+1518+1246+
1518+1518+1518+1450
(=17774) bytes
The "stuttering" of the value 1518 makes me wonder if the BDE (or possibly
gds32) is attempting a query; timing out; and then re-sending. OTOH, the
client doesn't resend. Could the server be looking for an ACK and
re-sending if one doesn't come through?
5. I have other queries (you know, the kind that actually gets data to
work with) that get sent up to four times in succession. This looks to be a
true timeout/resend sequence.
My point (and I do have one!) and questions are:
a. This traffic seems excessive. Do you agree?
b. Where does it originate: bde? gds32? tcp/ip?
c. Would I get less traffic if I switched to IBObjects?
d. How can I reduce it?
Any suggestions or pointers will be greatly appreciated.
Art Metz
AMetz@...