pranavbhole opened a new pull request, #15501:
URL: https://github.com/apache/druid/pull/15501

   ### Description
   After updating avatica client, it mandatory to set transparent_reconnection 
flag in jdbc uri to make sure that client does reconnect, ideally we should be 
see no such connection only from connectionSync request, if client is not 
setting flag then we see it from prepare phase itself that seems like a gap. 
This PR prints associated sql if it fails from prepare or prepareAndExecute  
avatica calls. It can help to trace the origin of client and fix it.
   
   ```
   org.apache.calcite.avatica.NoSuchConnectionException: null
        at 
org.apache.druid.sql.avatica.DruidMeta.getDruidConnection(DruidMeta.java:845) 
~[druid-sql.jar]
        at org.apache.druid.sql.avatica.DruidMeta.prepare(DruidMeta.java:274) 
~[druid-sql.jar]
        at 
org.apache.calcite.avatica.remote.LocalService.apply(LocalService.java:201) 
~[avatica-core-1.23.0.jar:1.23.0]
        at 
org.apache.calcite.avatica.remote.Service$PrepareRequest.accept(Service.java:1240)
 ~[avatica-core-1.23.0.jar:1.23.0]
        at 
org.apache.calcite.avatica.remote.Service$PrepareRequest.accept(Service.java:1211)
 ~[avatica-core-1.23.0.jar:1.23.0]
   ```
   
   This PR has:
   
   - [ ] been self-reviewed.
      - [ ] using the [concurrency 
checklist](https://github.com/apache/druid/blob/master/dev/code-review/concurrency.md)
 (Remove this item if the PR doesn't have any relation to concurrency.)
   - [ ] added documentation for new or modified features or behaviors.
   - [ ] a release note entry in the PR description.
   - [ ] added Javadocs for most classes and all non-trivial methods. Linked 
related entities via Javadoc links.
   - [ ] added or updated version, license, or notice information in 
[licenses.yaml](https://github.com/apache/druid/blob/master/dev/license.md)
   - [ ] added comments explaining the "why" and the intent of the code 
wherever would not be obvious for an unfamiliar reader.
   - [ ] added unit tests or modified existing tests to cover new code paths, 
ensuring the threshold for [code 
coverage](https://github.com/apache/druid/blob/master/dev/code-review/code-coverage.md)
 is met.
   - [ ] added integration tests.
   - [ ] been tested in a test Druid cluster.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to