Skip to content

Commit

Permalink
more logs 2
Browse files Browse the repository at this point in the history
  • Loading branch information
alexradzin committed Aug 2, 2023
1 parent bd6d688 commit 5118282
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions src/integrationTest/java/integration/tests/IsReadableTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,22 @@ public class IsReadableTest extends IntegrationTest {
void connection() throws SQLException {
try (Connection connection = createConnection()) {
log.info("connection test");

log.info("all engines");
PreparedStatement ps0 = connection.prepareStatement("select engine_name from information_schema.engines");
ResultSet rs0 = ps0.executeQuery();
while (rs0.next()) {
log.info("engine name: {}", rs0.getString(1));
}
log.info("and of all engines");

String engine = ((FireboltConnection)connection).getEngine();
log.info("engine={}", engine);
PreparedStatement ps1 = connection.prepareStatement("select engine_name from information_schema.engines where status = 'Running' and engine_type = 'General Purpose' and lower(engine_name) = lower(?)");
PreparedStatement ps1 = connection.prepareStatement("select engine_name, status, engine_type from information_schema.engines where lower(engine_name) = lower(?)");
ps1.setString(1, engine);
ResultSet rs1 = ps1.executeQuery();
while (rs1.next()) {
String engineName = rs1.getString(1);
log.info("engineName={}", engineName);
log.info("engine: {},{},{}.", rs1.getString(1), rs1.getString(2), rs1.getString(3));
}
log.info("end of the engines list");

Expand Down

0 comments on commit 5118282

Please sign in to comment.