2.7 JDBC Introduction, Needs for JDBC
-
JDBC introduction given in section – 2.1.
v
Needs for JDBC are
as above:
1) Performance :
§ Connecting to
the database is expensive and slow.
§ Pooled
connections can be left physically connected to the database
§ And shared
amongst the various components that need database access.
§ That way the
connection cost is paid for once and amortized across all the consuming
components.
2) Diagnostics :
§ If we have one
sub-system responsible for connecting to the database, it becomes easier to
diagnose and analyze database connection usage.
3) Maintainability
:
§ Again, if we
have one sub-system responsible for handing out database connections.
§ Wer code will be
easier to maintain than if each component connected to the database itself.
-
Because
JDBC is a Java API, it offers a natural Java interface for working with SQL.
-
JDBC
is needed to provide a "pure Java" solution for application
development.
No comments:
Post a Comment