public class TracingProxyDriver extends Object implements Driver
Invocation:
To set up a tracing version of a JDBC connection:
The proxying URL corresponding to an original URL is
"jdbc:proxy:original.Driver:original_URL",
where:
original.Driver is the fully qualified name of
the driver class to proxy and trace (used to load the class to get it
registered with JDBC's DriverManager, when or in case it's
not already loaded) and can be blank if the driver class will already
be loaded, and
original_URL is the original URL for the JDBC
data source to now be traced.
For example, for an original URL of "jdbc:drill:zk=local", the
tracing URL is
"jdbc:proxy:org.apache.drill.jdbc.Driver:jdbc:drill:zk=local".
TracingProxyDriver will be loaded (e.g.,
configure the client to use it as the driver class).
Output:
Currently, the tracing output lines are simply written to
System.out (stdout or "standard output").
| Constructor and Description |
|---|
TracingProxyDriver() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
acceptsURL(String url) |
Connection |
connect(String url,
Properties info) |
int |
getMajorVersion() |
int |
getMinorVersion() |
Logger |
getParentLogger() |
DriverPropertyInfo[] |
getPropertyInfo(String url,
Properties info) |
boolean |
jdbcCompliant() |
public TracingProxyDriver()
throws SQLException
SQLExceptionpublic boolean acceptsURL(String url) throws SQLException
acceptsURL in interface DriverSQLExceptionpublic Connection connect(String url, Properties info) throws org.apache.drill.jdbc.proxy.ProxySetupSQLException
public DriverPropertyInfo[] getPropertyInfo(String url, Properties info) throws SQLException
getPropertyInfo in interface DriverSQLExceptionpublic int getMajorVersion()
getMajorVersion in interface Driverpublic int getMinorVersion()
getMinorVersion in interface Driverpublic boolean jdbcCompliant()
jdbcCompliant in interface Driverpublic Logger getParentLogger() throws SQLFeatureNotSupportedException
getParentLogger in interface DriverSQLFeatureNotSupportedExceptionCopyright © 2021 The Apache Software Foundation. All rights reserved.