DataGateway provides a JDBC monitoring class which can monitor or manipulate JDBC traffic. JBuilder provides the JDBC Monitor, invoked from Tools|JDBC Monitor, to work with this class at design time. For information on using this class at run time, see Using the JDBC Monitor in a running application in the Database Application Developer's Guide.
JDBC Monitor will monitor any JDBC driver (i.e., any subclass of java.sql.Driver) while it is in use by JBuilder. However, the monitor works best, and is most informative with, Borland's DataGateway JDBC drivers. See the Database Application Developer's Guide topic, Monitoring database connections for more information.
The JDBC Monitor can be used during the design process or while debugging a JBuilder application to display trace output from the driver. The three controls that enable you to set up JDBC Monitor are:
For more information on JDBC Monitor, consult Borland's DataGateway Online User's Guide, available from the DataGateway group when DataGateway is installed.If you choose the Borland Bridge (or Local) Monitor, you can monitor the output from a single alias or from all listed aliases.
After you define a server, JDBC Monitor displays a list of URLs for every alias defined on that machine, including an option to monitor all aliases on that machine. This gives instant connectivity to all BDE drivers running on another machine (i.e., the "middle tier"). Selection of a single alias will restrict monitoring to that alias.
To monitor more than one source, you must bring up another instance of the Monitor window.
The following table describes the output you will see in the JDBC Monitor depending on which source is selected. In this table and in this document, Local and Bridge are synonymous and Remote and Broker are synonymous. The log output from DataGateway is quite different from the output from JDBC.
Driver Class | Output Intercepted | Description |
java.sql.Driver | DriverManager.getLogStream() | Standard JDBC driver class. The logStream is supported by the single driver Manager, so there is just one log stream for all of the JDBC drivers running under a VM. |
borland.jdbc.Bridge.LocalDriver | borland.jdbc.Bridge.Monitor | A monitor is a streamable output which can be attached at one of two levels:
|
borland.jdbc.Broker.RemoteDriver | borland.jdbc.Broker.Monitor | The Broker monitor works similarly to the Bridge monitor, but for remote connections. To use the remote monitor, you must first specify a server name where the Borland Broker is running. You may then attach the monitor at one of two levels:
|
The Traces control displays a menu of options for selecting the type of tracing you can enable. This control is only useful when tracing a Borland Driver (either Local or Remote). The trace control offers five options. The description of each option is provided by Borland DataGateway.
You can select to display any combination of these five trace types, depending on the type and detail of information you want to display.