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

SqlStatement: bind uri and uuid #1768

Merged
merged 2 commits into from
Oct 1, 2020
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.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 4 additions & 0 deletions RELEASE_NOTES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# 3.15.0
- Significant performance improvements for data intensive workloads
- bind() overloads for UUID and URI, see #1765

# 3.14.5
- SqlBatch: fix inserting of constant `null` value, #1761

Expand Down
2 changes: 1 addition & 1 deletion benchmark/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-benchmark</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion bom/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-bom</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion commons-text/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>
<artifactId>jdbi3-commons-text</artifactId>

Expand Down
2 changes: 1 addition & 1 deletion core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-core</artifactId>
Expand Down
50 changes: 50 additions & 0 deletions core/src/main/java/org/jdbi/v3/core/statement/SqlStatement.java
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
import java.io.Reader;
import java.lang.reflect.Type;
import java.math.BigDecimal;
import java.net.URI;
import java.net.URL;
import java.sql.Blob;
import java.sql.Clob;
Expand All @@ -29,6 +30,7 @@
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.UUID;
import java.util.function.BiConsumer;
import java.util.function.Consumer;
import java.util.function.Supplier;
Expand Down Expand Up @@ -1076,6 +1078,54 @@ public final This bind(String name, URL value) {
return bindByType(name, value, URL.class);
}

/**
* Bind an argument positionally
*
* @param position position to bind the parameter at, starting at 0
* @param value to bind
*
* @return the same Query instance
*/
public final This bind(int position, URI value) {
return bindByType(position, value, URI.class);
}

/**
* Bind an argument by name
*
* @param name token name to bind the parameter to
* @param value to bind
*
* @return the same Query instance
*/
public final This bind(String name, URI value) {
return bindByType(name, value, URI.class);
}

/**
* Bind an argument positionally
*
* @param position position to bind the parameter at, starting at 0
* @param value to bind
*
* @return the same Query instance
*/
public final This bind(int position, UUID value) {
return bindByType(position, value, UUID.class);
}

/**
* Bind an argument by name
*
* @param name token name to bind the parameter to
* @param value to bind
*
* @return the same Query instance
*/
public final This bind(String name, UUID value) {
return bindByType(name, value, UUID.class);
}

/**
* Bind an argument dynamically by the type passed in.
*
Expand Down
2 changes: 1 addition & 1 deletion docs/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-docs</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion freemarker/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-freemarker</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion generator/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-generator</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion gson2/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-gson2</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion guava/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-guava</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion jackson2/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-jackson2</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion jodatime2/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-jodatime2</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion jpa/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-jpa</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion json/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-json</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion kotlin-sqlobject/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-kotlin-sqlobject</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion kotlin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-kotlin</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion noparameters/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-noparameters</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion policy/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

<groupId>org.jdbi</groupId>
<artifactId>jdbi3-policy</artifactId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
<name>jdbi3 Policy</name>
<description>Policy files for Jdbi build configuration</description>
</project>
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@

<groupId>org.jdbi</groupId>
<artifactId>jdbi3-parent</artifactId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
<packaging>pom</packaging>
<name>jdbi3 Parent</name>
<description>Jdbi is designed to provide convenient tabular data access in
Expand Down
2 changes: 1 addition & 1 deletion postgres/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-postgres</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion spring4/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-spring4</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion spring5/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-spring5</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion sqlite/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-sqlite</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion sqlobject/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-sqlobject</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion stringtemplate4/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-stringtemplate4</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion testing/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-testing</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion vavr/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<parent>
<artifactId>jdbi3-parent</artifactId>
<groupId>org.jdbi</groupId>
<version>3.14.5-SNAPSHOT</version>
<version>3.15.0-SNAPSHOT</version>
</parent>

<artifactId>jdbi3-vavr</artifactId>
Expand Down