Skip to content

Commit

Permalink
Java version updated
Browse files Browse the repository at this point in the history
Code comment added
  • Loading branch information
jlolling committed Oct 8, 2020
1 parent 3fff17b commit d3b376a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 13 deletions.
13 changes: 2 additions & 11 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.7</source>
<target>1.7</target>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
<plugin>
Expand Down Expand Up @@ -100,15 +100,6 @@
<version>9.4.1212.jre7</version>
<scope>provided</scope>
</dependency>
<!--
<dependency>
<groupId>sqlrunner</groupId>
<artifactId>sqlrunner</artifactId>
<version>18.2</version>
<scope>system</scope>
<systemPath>${project.basedir}/lib/sqlrunner-18.2.jar</systemPath>
</dependency>
-->
</dependencies>
<version>9.4</version>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -542,9 +542,12 @@ private final void writeTable() {
if (one == null) {
continue;
} else {
// because poll removes already the one object
// we have to add it here
queueObjects.add(one);
}
// drain never waits! Thats why we have to use poll before!
// here we get the rest of all objects from the queue
tableQueue.drainTo(queueObjects, batchSize); // pull elements from queue to this given list
// debug("Got " + queueObjects.size() + " records from queue.");
for (Object item : queueObjects) {
Expand Down Expand Up @@ -809,8 +812,8 @@ public final void setup() throws Exception {
if (outputToTable) {
createTargetInsertStatement();
}
final int batchSize = Integer.parseInt(properties.getProperty(TARGET_BATCHSIZE, "100"));
final int fetchSize = Integer.parseInt(properties.getProperty(SOURCE_FETCHSIZE, "100"));
final int batchSize = Integer.parseInt(properties.getProperty(TARGET_BATCHSIZE, "1000"));
final int fetchSize = Integer.parseInt(properties.getProperty(SOURCE_FETCHSIZE, "1000"));
final int queueSize = Math.max(batchSize, fetchSize);
if (outputToTable) {
tableQueue = new ArrayBlockingQueue<Object>(queueSize);
Expand Down

0 comments on commit d3b376a

Please sign in to comment.