JDBC Driver issues

I'm currently facing issues while using the Elastic Cloud in conjunction with the latest JDBC Driver(7.3.1).

Dispatching queries works, however, sometimes when sending a high amount of queries simultaneously, i'll receive the following error:

An error occurred executing SQL:
SELECT way, abbreviation, SCORE() FROM cep WHERE MATCH('way,abbreviation', 'this is a query', 'fuzziness=AUTO') AND city = 'this is a query' AND state = 'this is a query' ORDER BY SCORE() DESC LIMIT 1
Cannot POST address {{omitted for the forums}}/_sql?error_trace (No route to host(Host unreachable))

Wich is odd, since this endpoint is getting called anyways since i'm using the JDBC driver.
The stacktrace itself returns:

{"error":{"root_cause":[{"type":"parse_exception","reason":"request body or source parameter is required","stack_trace":"ElasticsearchParseException[request body or source parameter is required]...[truncated]

I checked the queries being dispatched and there is no empty body, afterwards, the whole connection closes:

Caused by: java.sql.SQLException: org.apache.commons.dbcp.DelegatingStatement with address: "org.elasticsearch.xpack.sql.jdbc.JdbcStatement@551657d8" is closed.

Thank you for the support.

@ubi couple of things here:

  • there is no need (and doesn't make a difference if using) for dbcp pooling, as the ES SQL connections don't have state and you do not save on resources if you are reusing a connection. I suggest removing the dbcp layer.
  • "high amount of queries simultaneously" - what values are we talking about?
  • can you post the complete stacktrace for the "No route to host" error?

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.