Chapter 3 Troubleshooting
Tabular Data Stream (TDS) is Sybase's proprietary protocol for handling communication between a client application and Adaptive Server. jConnect includes a PROTOCOL_CAPTURE connection property that allows you to capture raw TDS packets to a file.
If you are having problems with an application that you cannot resolve within either the application or the server, you can use PROTOCOL_CAPTURE to capture the communication between the client and the server in a file. You can then send the file, which contains binary data and is not directly interpretable, to Sybase Technical Support for analysis.
You can also use the Ribo utility
to capture, translate, and display the protocol stream flowing between
the client and the server. For details on how to obtain and use Ribo,
visit the jConnect utilities Web page at http://www.sybase.com/products/internet/jconnect/utilities/
Use the PROTOCOL_CAPTURE connection property to specify a file for receiving the TDS packets exchanged between an application and an Adaptive Server. PROTOCOL_CAPTURE takes effect immediately so that TDS packets exchanged during connection establishment are written to the specified file. All packets continue to be written to the file until Capture.pause( ) is executed or the session is closed.
The following example shows the use of PROTOCOL_CAPTURE to send TDS data to the file tds_data:
... props.put("PROTOCOL_CAPTURE", "tds_data") Connection conn = DriverManager.getConnection(url, props);
where url is the connection URL and props is a Properties object for specifying connection properties.
The Capture class is contained in the com.sybase.jdbcx package. It contains two public methods:
Capture.pause( ) stops the capture of raw TDS packets into a file; Capture.resume( ) restarts the capture.
The TDS capture file for an entire session can become very large. If you want to limit the size of the capture file, and you know where in an application you want to capture TDS data, you can do the following:
Capture cap = ((SybConnection)conn).getCapture(); cap.pause();
Copyright © 2001 Sybase, Inc. All rights reserved. |
![]() |