This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes JDBC and the fly likes JDBC: Minimum network bandwidth required Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "JDBC: Minimum network bandwidth required" Watch "JDBC: Minimum network bandwidth required" New topic
Author

JDBC: Minimum network bandwidth required

Shadab F Hashmi
Greenhorn

Joined: Feb 13, 2006
Posts: 9
Hi All,

I have a small query regarding JDBC connectivity over WAN. I have scenerio where my application is running say 'San Francisco' and Database server is at another place say 'New York'. When i want to connect to database server on WAN using JDBC, what is the minimum network bandwidth/latency required to successfully connect to database server.Does JDBC have any recommended range of latency?

Thanks inadvance for your help.

Regards,
Shadab.
stu derby
Ranch Hand

Joined: Dec 15, 2005
Posts: 333
There's no particular JDBC requirement. JDBC as a standard is independent of the underlying network layer, but most JDBC drivers are built on TCP/IP and merely require reasonably long-lived connections. Dealing with connection interruptions can be a significant design problem for "difficult" networking conditions. It's more a matter of whether your program can deliver acceptable performance, as judged by users.

There are two pieces of performance advice for some-one developing such a "long-haul" application:
1. connection pooling - connect time can be very significant even on a "short haul"; in a test I did recently, not using connection pooling when connecting through a VPN tunnel made a very simple test program perform 800% slower.
2. Statement.setFetchSize() (or Connection.setPrefetchSize() if you're using Oracle) - ResultSet row retrieval can be buffered to significantly improve performance and manage memory usage.

I'm assuming your database port is secured somehow, such as via a VPN tunnel. If it's not, if the port is open to the Internet, it will be found by hackers and attacked; if there's any security errors in the database program, the hackers will get in.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: JDBC: Minimum network bandwidth required
 
Similar Threads
Connecting to Database server
Network Bandwidth consumed, slows application
Fetching ResultSet into Java Objects.
Remote JDBC connection performance question
Tell Clients a Record is locked/updated?