forked from dork/tarantool-java
-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add support for JDBC batch updates. It includes an implementation of Statement.*Batch(...) as well as PreparedStatement.*Batch() methods. Under the hood SQLConnection uses the pipelining sending requests one by one asynchronously and awaiting all of them. There are some issues regarding vinyl storage engine where execution order are not specified and DDL statements which are not transactional. Closes: #62
- Loading branch information
1 parent
b53e0ba
commit 05bfde6
Showing
10 changed files
with
511 additions
and
73 deletions.
There are no files selected for viewing
26 changes: 26 additions & 0 deletions
26
src/main/java/org/tarantool/jdbc/SQLBatchResultHolder.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
package org.tarantool.jdbc; | ||
|
||
import java.util.List; | ||
|
||
/** | ||
* Wrapper for batch SQL query results. | ||
*/ | ||
public class SQLBatchResultHolder { | ||
|
||
private final List<SQLResultHolder> results; | ||
private final Exception error; | ||
|
||
public SQLBatchResultHolder(List<SQLResultHolder> results, Exception error) { | ||
this.results = results; | ||
this.error = error; | ||
} | ||
|
||
public List<SQLResultHolder> getResults() { | ||
return results; | ||
} | ||
|
||
public Exception getError() { | ||
return error; | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.