Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Automated]JDBC Driver Release 1.3.12 #209

Merged
merged 1 commit into from
Oct 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions tools/etl/tg-jdbc-driver/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## Release 1.3.12
* Supported TG Version: 2.4.1+
* Ensuring compatibility with Java 8.

## Release 1.3.11
* Supported TG Version: 2.4.1+
* Bugfixes:
Expand Down
28 changes: 27 additions & 1 deletion tools/etl/tg-jdbc-driver/tg-jdbc-driver/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

<groupId>com.tigergraph</groupId>
<artifactId>tigergraph-jdbc-driver</artifactId>
<version>1.3.11</version>
<version>1.3.12</version>
<packaging>jar</packaging>

<name>TigerGraph JDBC Driver Parent</name>
Expand Down Expand Up @@ -129,6 +129,32 @@
<!-- default build plugins -->
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.1</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>animal-sniffer-maven-plugin</artifactId>
<version>1.19</version>
<executions>
<execution>
<id>check-java-8-compatibility</id>
<phase>compile</phase>
<goals>
<goal>check</goal>
</goals>
<configuration>
<signature>
<groupId>org.codehaus.mojo.signature</groupId>
<artifactId>java18</artifactId>
<version>1.0</version>
</signature>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@
import java.util.Properties;
import java.util.List;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Base64;
import java.util.Random;
import org.slf4j.Logger;
Expand Down Expand Up @@ -197,14 +198,16 @@ public RestppConnection(
this.maxRetryCount = Integer.valueOf(properties.getProperty("maxRetryCount"));
}

// Starting from v3.9.0, TG supports providing loading job statistics based on jobid
// Starting from v3.9.0, TG supports providing loading job statistics based on
// jobid
if (properties.containsKey("jobid")
&& this.tg_version.compareTo(new ComparableVersion("3.9.0")) >= 0) {
this.jobid = properties.getProperty("jobid");
logger.info("The loading job ID of current connection: {}", this.jobid);
}

// Starting from v3.9.0, TG supports terminating loading jobs based on the max number of
// Starting from v3.9.0, TG supports terminating loading jobs based on the max
// number of
// errors.
if (properties.containsKey("max_num_error")
&& this.tg_version.compareTo(new ComparableVersion("3.9.0")) >= 0) {
Expand All @@ -214,7 +217,8 @@ public RestppConnection(
}
}

// Starting from v3.9.0, TG supports terminating loading jobs based on the max percentage of
// Starting from v3.9.0, TG supports terminating loading jobs based on the max
// percentage of
// errors.
if (properties.containsKey("max_percent_error")
&& this.tg_version.compareTo(new ComparableVersion("3.9.0")) >= 0) {
Expand Down Expand Up @@ -382,7 +386,8 @@ public RestppConnection(
builder.setUserAgent(userAgent);
}
// Set the timeout for establishing a connection
// The socketTimeout should be longer then queryTimeout to avoid timeout before query finishes
// The socketTimeout should be longer then queryTimeout to avoid timeout before
// query finishes
this.socketTimeout = Math.max(this.socketTimeout, this.queryTimeout + 5 * 60);
builder.setDefaultRequestConfig(
RequestConfig.custom()
Expand Down Expand Up @@ -436,7 +441,7 @@ public RestppConnection(
private int count = 1;
private String cause;
private static final long maxRetryInterval = 10 * 60 * 1000; // 10min
private final List<Integer> retriableCode = List.of(408, 500, 502, 503, 504);
private final List<Integer> retriableCode = Arrays.asList(408, 500, 502, 503, 504);

@Override
public boolean retryRequest(
Expand Down
Loading