Skip to content
Permalink
Browse files

[CONJ-654] correct metadata driver name along with getDatabaseProduct…

…Name() according to server.

misc wrong "MySQL" description changed to "MariaDB"

(cherry picked from commit 5ec5099)
  • Loading branch information...
rusher committed Oct 5, 2018
1 parent 8e64d6d commit cc0ae015ea4e7bdd0e4ee145535ef77995efdce3

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

@@ -254,7 +254,7 @@ public SelectResultSet(ColumnInformation[] columnInformation, List<byte[]> resul
*
* @param data - each element of this array represents a complete row in the
* ResultSet. Each value is given in its string representation, as in
* MySQL text protocol, except boolean (BIT(1)) values that are
* MariaDB text protocol, except boolean (BIT(1)) values that are
* represented as "1" or "0" strings
* @param protocol protocol
* @param findColumnReturnsOne - special parameter, used only in generated key result sets
@@ -289,7 +289,7 @@ public int findColumn(String name) {
* @param columnNames - string array of column names
* @param columnTypes - column types
* @param data - each element of this array represents a complete row in the ResultSet.
* Each value is given in its string representation, as in MySQL text protocol,
* Each value is given in its string representation, as in MariaDB text protocol,
* except boolean (BIT(1)) values that are represented as "1" or "0" strings
* @param protocol protocol
* @return resultset

Large diffs are not rendered by default.

@@ -54,47 +54,47 @@

public class TraceObject {

public static final int NOT_COMPRESSED = 0;
public static final int COMPRESSED_PROTOCOL_COMPRESSED_PACKET = 1;
public static final int COMPRESSED_PROTOCOL_NOT_COMPRESSED_PACKET = 2;
public static final int NOT_COMPRESSED = 0;
public static final int COMPRESSED_PROTOCOL_COMPRESSED_PACKET = 1;
public static final int COMPRESSED_PROTOCOL_NOT_COMPRESSED_PACKET = 2;

private final boolean send;
private final int indicatorFlag;
private byte[][] buf;
private final boolean send;
private final int indicatorFlag;
private byte[][] buf;

/**
* Permit to store MySQL packets.
*
* @param send was packet send or received
* @param indicatorFlag indicator. can be NOT_COMPRESSED, COMPRESSED_PROTOCOL_COMPRESSED_PACKET or
* COMPRESSED_PROTOCOL_NOT_COMPRESSED_PACKET
* @param buf buffers
*/
public TraceObject(boolean send, int indicatorFlag, byte[]... buf) {
this.send = send;
this.indicatorFlag = indicatorFlag;
this.buf = buf;
}
/**
* Permit to store MariaDB packets.
*
* @param send was packet send or received
* @param indicatorFlag indicator. can be NOT_COMPRESSED, COMPRESSED_PROTOCOL_COMPRESSED_PACKET or
* COMPRESSED_PROTOCOL_NOT_COMPRESSED_PACKET
* @param buf buffers
*/
public TraceObject(boolean send, int indicatorFlag, byte[]... buf) {
this.send = send;
this.indicatorFlag = indicatorFlag;
this.buf = buf;
}

/**
* Clear trace array for easy garbage.
*/
public void remove() {
for (int i = 0; i < buf.length; i++) {
buf[i] = null;// force null for easier garbage
}
buf = null;
/**
* Clear trace array for easy garbage.
*/
public void remove() {
for (int i = 0; i < buf.length; i++) {
buf[i] = null;// force null for easier garbage
}
buf = null;
}

public boolean isSend() {
return send;
}
public boolean isSend() {
return send;
}

public int getIndicatorFlag() {
return indicatorFlag;
}
public int getIndicatorFlag() {
return indicatorFlag;
}

public byte[][] getBuf() {
return buf;
}
public byte[][] getBuf() {
return buf;
}
}

0 comments on commit cc0ae01

Please sign in to comment.
You can’t perform that action at this time.