diff --git a/wrapper/src/main/java/software/amazon/jdbc/C3P0PooledConnectionProvider.java b/wrapper/src/main/java/software/amazon/jdbc/C3P0PooledConnectionProvider.java index 466e61e64..c7c5afff9 100644 --- a/wrapper/src/main/java/software/amazon/jdbc/C3P0PooledConnectionProvider.java +++ b/wrapper/src/main/java/software/amazon/jdbc/C3P0PooledConnectionProvider.java @@ -36,7 +36,6 @@ import software.amazon.jdbc.util.Messages; import software.amazon.jdbc.util.PropertyUtils; import software.amazon.jdbc.util.SlidingExpirationCache; -import software.amazon.jdbc.wrapper.HighestWeightHostSelector; public class C3P0PooledConnectionProvider implements PooledConnectionProvider, CanReleaseResources { diff --git a/wrapper/src/main/java/software/amazon/jdbc/DataSourceConnectionProvider.java b/wrapper/src/main/java/software/amazon/jdbc/DataSourceConnectionProvider.java index 91b4368d4..0231739d0 100644 --- a/wrapper/src/main/java/software/amazon/jdbc/DataSourceConnectionProvider.java +++ b/wrapper/src/main/java/software/amazon/jdbc/DataSourceConnectionProvider.java @@ -32,14 +32,12 @@ import org.checkerframework.checker.nullness.qual.Nullable; import software.amazon.jdbc.dialect.Dialect; import software.amazon.jdbc.exceptions.SQLLoginException; -import software.amazon.jdbc.targetdriverdialect.ConnectInfo; import software.amazon.jdbc.targetdriverdialect.TargetDriverDialect; import software.amazon.jdbc.util.Messages; import software.amazon.jdbc.util.PropertyUtils; import software.amazon.jdbc.util.RdsUtils; import software.amazon.jdbc.util.SqlState; import software.amazon.jdbc.util.WrapperUtils; -import software.amazon.jdbc.wrapper.HighestWeightHostSelector; /** * This class is a basic implementation of {@link ConnectionProvider} interface. It creates and diff --git a/wrapper/src/main/java/software/amazon/jdbc/DriverConnectionProvider.java b/wrapper/src/main/java/software/amazon/jdbc/DriverConnectionProvider.java index 32e85a9cc..135eabc4b 100644 --- a/wrapper/src/main/java/software/amazon/jdbc/DriverConnectionProvider.java +++ b/wrapper/src/main/java/software/amazon/jdbc/DriverConnectionProvider.java @@ -35,7 +35,6 @@ import software.amazon.jdbc.util.Messages; import software.amazon.jdbc.util.PropertyUtils; import software.amazon.jdbc.util.RdsUtils; -import software.amazon.jdbc.wrapper.HighestWeightHostSelector; /** * This class is a basic implementation of {@link ConnectionProvider} interface. It creates and diff --git a/wrapper/src/main/java/software/amazon/jdbc/wrapper/HighestWeightHostSelector.java b/wrapper/src/main/java/software/amazon/jdbc/HighestWeightHostSelector.java similarity index 92% rename from wrapper/src/main/java/software/amazon/jdbc/wrapper/HighestWeightHostSelector.java rename to wrapper/src/main/java/software/amazon/jdbc/HighestWeightHostSelector.java index 4899f0b54..a6b04ad48 100644 --- a/wrapper/src/main/java/software/amazon/jdbc/wrapper/HighestWeightHostSelector.java +++ b/wrapper/src/main/java/software/amazon/jdbc/HighestWeightHostSelector.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package software.amazon.jdbc.wrapper; +package software.amazon.jdbc; import java.sql.SQLException; import java.util.Comparator; @@ -23,9 +23,6 @@ import java.util.stream.Collectors; import org.checkerframework.checker.nullness.qual.NonNull; import org.checkerframework.checker.nullness.qual.Nullable; -import software.amazon.jdbc.HostRole; -import software.amazon.jdbc.HostSelector; -import software.amazon.jdbc.HostSpec; import software.amazon.jdbc.hostavailability.HostAvailability; import software.amazon.jdbc.util.Messages; diff --git a/wrapper/src/main/java/software/amazon/jdbc/HikariPooledConnectionProvider.java b/wrapper/src/main/java/software/amazon/jdbc/HikariPooledConnectionProvider.java index dd6f6e741..a0aca078a 100644 --- a/wrapper/src/main/java/software/amazon/jdbc/HikariPooledConnectionProvider.java +++ b/wrapper/src/main/java/software/amazon/jdbc/HikariPooledConnectionProvider.java @@ -44,7 +44,6 @@ import software.amazon.jdbc.util.RdsUrlType; import software.amazon.jdbc.util.RdsUtils; import software.amazon.jdbc.util.SlidingExpirationCache; -import software.amazon.jdbc.wrapper.HighestWeightHostSelector; public class HikariPooledConnectionProvider implements PooledConnectionProvider, CanReleaseResources { diff --git a/wrapper/src/main/java/software/amazon/jdbc/plugin/limitless/LimitlessRouterServiceImpl.java b/wrapper/src/main/java/software/amazon/jdbc/plugin/limitless/LimitlessRouterServiceImpl.java index f5502617d..24500a7d2 100644 --- a/wrapper/src/main/java/software/amazon/jdbc/plugin/limitless/LimitlessRouterServiceImpl.java +++ b/wrapper/src/main/java/software/amazon/jdbc/plugin/limitless/LimitlessRouterServiceImpl.java @@ -26,6 +26,7 @@ import java.util.logging.Logger; import org.checkerframework.checker.nullness.qual.NonNull; import software.amazon.jdbc.AwsWrapperProperty; +import software.amazon.jdbc.HighestWeightHostSelector; import software.amazon.jdbc.HostRole; import software.amazon.jdbc.HostSpec; import software.amazon.jdbc.PluginService; @@ -35,7 +36,6 @@ import software.amazon.jdbc.util.Messages; import software.amazon.jdbc.util.SlidingExpirationCacheWithCleanupThread; import software.amazon.jdbc.util.Utils; -import software.amazon.jdbc.wrapper.HighestWeightHostSelector; public class LimitlessRouterServiceImpl implements LimitlessRouterService { private static final Logger LOGGER = diff --git a/wrapper/src/main/java/software/amazon/jdbc/wrapper/ArrayWrapper.java b/wrapper/src/main/java/software/amazon/jdbc/wrapper/ArrayWrapper.java index f14881603..11d846780 100644 --- a/wrapper/src/main/java/software/amazon/jdbc/wrapper/ArrayWrapper.java +++ b/wrapper/src/main/java/software/amazon/jdbc/wrapper/ArrayWrapper.java @@ -75,7 +75,8 @@ public Object getArray(Map> map) throws SQLException { this.pluginManager, this.array, "Array.getArray", - () -> this.array.getArray()); + () -> this.array.getArray(map), + map); } @Override @@ -86,7 +87,9 @@ public Object getArray(long index, int count) throws SQLException { this.pluginManager, this.array, "Array.getArray", - () -> this.array.getArray()); + () -> this.array.getArray(index, count), + index, + count); } @Override @@ -97,7 +100,10 @@ public Object getArray(long index, int count, Map> map) throws this.pluginManager, this.array, "Array.getArray", - () -> this.array.getArray()); + () -> this.array.getArray(index, count, map), + index, + count, + map); } @Override @@ -119,7 +125,8 @@ public ResultSet getResultSet(Map> map) throws SQLException { this.pluginManager, this.array, "Array.getResultSet", - () -> this.array.getResultSet()); + () -> this.array.getResultSet(map), + map); } @Override @@ -130,7 +137,9 @@ public ResultSet getResultSet(long index, int count) throws SQLException { this.pluginManager, this.array, "Array.getResultSet", - () -> this.array.getResultSet()); + () -> this.array.getResultSet(index, count), + index, + count); } @Override diff --git a/wrapper/src/test/java/software/amazon/jdbc/plugin/HighestWeightHostSelectorTest.java b/wrapper/src/test/java/software/amazon/jdbc/plugin/HighestWeightHostSelectorTest.java index 9c8e9f26d..aeaabbaeb 100644 --- a/wrapper/src/test/java/software/amazon/jdbc/plugin/HighestWeightHostSelectorTest.java +++ b/wrapper/src/test/java/software/amazon/jdbc/plugin/HighestWeightHostSelectorTest.java @@ -26,11 +26,11 @@ import java.util.Properties; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; +import software.amazon.jdbc.HighestWeightHostSelector; import software.amazon.jdbc.HostRole; import software.amazon.jdbc.HostSpec; import software.amazon.jdbc.HostSpecBuilder; import software.amazon.jdbc.hostavailability.SimpleHostAvailabilityStrategy; -import software.amazon.jdbc.wrapper.HighestWeightHostSelector; public class HighestWeightHostSelectorTest { diff --git a/wrapper/src/test/java/software/amazon/jdbc/plugin/limitless/LimitlessRouterServiceImplTest.java b/wrapper/src/test/java/software/amazon/jdbc/plugin/limitless/LimitlessRouterServiceImplTest.java index 8b90d7275..12e761087 100644 --- a/wrapper/src/test/java/software/amazon/jdbc/plugin/limitless/LimitlessRouterServiceImplTest.java +++ b/wrapper/src/test/java/software/amazon/jdbc/plugin/limitless/LimitlessRouterServiceImplTest.java @@ -38,6 +38,7 @@ import org.junit.jupiter.api.Test; import org.mockito.Mock; import org.mockito.MockitoAnnotations; +import software.amazon.jdbc.HighestWeightHostSelector; import software.amazon.jdbc.HostListProvider; import software.amazon.jdbc.HostRole; import software.amazon.jdbc.HostSpec; @@ -47,7 +48,6 @@ import software.amazon.jdbc.RoundRobinHostSelector; import software.amazon.jdbc.hostavailability.HostAvailability; import software.amazon.jdbc.hostavailability.SimpleHostAvailabilityStrategy; -import software.amazon.jdbc.wrapper.HighestWeightHostSelector; public class LimitlessRouterServiceImplTest {