Skip to content

Commit

Permalink
Flight SQL Ratification Based On Community Feedback #7 (apache#98)
Browse files Browse the repository at this point in the history
* Remove scope from 'hamcrest' dependency on java/pom.xml

* Use flight top-level module on parent pom.xml instead of declaring each one

* Avoid using getStatement inside StatementContext methods

* Make StatementContext.getQuery() return String

* Minor fixes on pom.xml

* Move 'os-maven-plugin' to parent pom.xml

* Update protobuf generation on pom.xml files

* Use ClassLoader#getResource to get network.properties on TestFlightSql

* Bind to any ephemeral port on TestFlightSql

* Move JDBC-Arrow type default conversion from JdbcToArrowConfig to JdbcToArrowUtils

* Micro-optimization: initialize ArrayList with the right size

* Fix null-check on PreparedStatement#setParameters

* Avoid wrapping vector into a ImmutableList and then into an ArrayList on FlightSqlExample#getTablesRoot

* Remove null-check on VectorSchemaRoot on FlightSqlClient#setParameters()

* Remove the need of separate cache for ResultSets

* Add missing 'final' modifiers
  • Loading branch information
rafael-telles authored and vfraga committed Mar 29, 2022
1 parent 957357b commit 17c9a4c
Show file tree
Hide file tree
Showing 3 changed files with 44 additions and 23 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,7 @@
import static org.hamcrest.CoreMatchers.notNullValue;
import static org.hamcrest.CoreMatchers.nullValue;

import java.io.ByteArrayInputStream;
import java.io.IOException;
import java.nio.channels.Channels;
import java.nio.ByteBuffer;
import java.sql.SQLException;
import java.util.ArrayList;
import java.util.Arrays;
Expand Down
31 changes: 11 additions & 20 deletions java/flight/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,8 @@
<packaging>pom</packaging>

<properties>
<dep.grpc.version>1.44.1</dep.grpc.version>
<dep.netty-tcnative.version>2.0.46.Final</dep.netty-tcnative.version>
<dep.protobuf.version>3.19.4</dep.protobuf.version>
<dep.grpc.version>1.30.2</dep.grpc.version>
<dep.protobuf.version>3.7.1</dep.protobuf.version>
</properties>

<modules>
Expand All @@ -38,22 +37,14 @@
</modules>

<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.xolstice.maven.plugins</groupId>
<artifactId>protobuf-maven-plugin</artifactId>
<version>0.6.1</version>
<configuration>
<protocArtifact>
com.google.protobuf:protoc:${dep.protobuf.version}:exe:${os.detected.classifier}
</protocArtifact>
<pluginId>grpc-java</pluginId>
<pluginArtifact>io.grpc:protoc-gen-grpc-java:${dep.grpc.version}:exe:${os.detected.classifier}
</pluginArtifact>
</configuration>
</plugin>
</plugins>
</pluginManagement>
<extensions>
<!-- provides os.detected.classifier (i.e. linux-x86_64, osx-x86_64) property -->
<extension>
<groupId>kr.motd.maven</groupId>
<artifactId>os-maven-plugin</artifactId>
<version>1.5.0.Final</version>
</extension>
</extensions>
</build>

</project>
32 changes: 32 additions & 0 deletions java/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -506,6 +506,38 @@
</lifecycleMappingMetadata>
</configuration>
</plugin>

<plugin>
<groupId>org.xolstice.maven.plugins</groupId>
<artifactId>protobuf-maven-plugin</artifactId>
<version>0.6.1</version>
<configuration>
<protocArtifact>com.google.protobuf:protoc:${dep.protobuf.version}:exe:${os.detected.classifier}</protocArtifact>
<pluginId>grpc-java</pluginId>
<pluginArtifact>io.grpc:protoc-gen-grpc-java:${dep.grpc.version}:exe:${os.detected.classifier}</pluginArtifact>
</configuration>
<executions>
<execution>
<id>proto-compile</id>
<phase>generate-sources</phase>
<configuration>
<protoSourceRoot>${basedir}/../format/</protoSourceRoot>
</configuration>
<goals>
<goal>compile</goal>
<goal>compile-custom</goal>
</goals>
</execution>
<execution>
<id>proto-test-compile</id>
<phase>generate-test-sources</phase>
<goals>
<goal>test-compile</goal>
<goal>test-compile-custom</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</pluginManagement>
</build>
Expand Down

0 comments on commit 17c9a4c

Please sign in to comment.