[
https://issues.apache.org/jira/browse/PHOENIX-3826?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15994324#comment-15994324
]
Samarth Jain commented on PHOENIX-3826:
---------------------------------------
Logging of the stacktrace was intentional. We wanted to track which clients are
creating new HConnections to the cluster. Because there is a 1:1 correspondence
between an instance of ConnectionQueryServices and HConnection, we can remove
the stacktrace for when an instance of ConnectionQueryServices is created. For
the HConnection stacktrace, my suggestion would be to have a more explicit log
message. Something like:
"This is not a bug. The stacktrace is being logged for informational purposes
to catch clients creating new HConnections". I would also recommend to remove
the java.lang.Exception from the stacktrace as it gives the impression that
something wrong has happened.
> Exception stack trace is being logged in info mode when new phoenix
> connection is created
> ------------------------------------------------------------------------------------------
>
> Key: PHOENIX-3826
> URL: https://issues.apache.org/jira/browse/PHOENIX-3826
> Project: Phoenix
> Issue Type: Bug
> Reporter: Loknath Priyatham Teja Singamsetty
> Assignee: Loknath Priyatham Teja Singamsetty
> Priority: Minor
>
> Exception is being raised when new phoenix connection is created
> 2017-05-03 05:51:39,898 INFO [main] query.ConnectionQueryServicesImpl - An
> instance of ConnectionQueryServices was created: java.lang.Exception
> at
> org.apache.phoenix.query.ConnectionQueryServicesImpl$12.call(ConnectionQueryServicesImpl.java:2401)
> at
> org.apache.phoenix.query.ConnectionQueryServicesImpl$12.call(ConnectionQueryServicesImpl.java:2378)
> at
> org.apache.phoenix.util.PhoenixContextExecutor.call(PhoenixContextExecutor.java:76)
> at
> org.apache.phoenix.query.ConnectionQueryServicesImpl.init(ConnectionQueryServicesImpl.java:2378)
> at
> org.apache.phoenix.jdbc.PhoenixDriver.getConnectionQueryServices(PhoenixDriver.java:255)
> at
> org.apache.phoenix.jdbc.PhoenixEmbeddedDriver.createConnection(PhoenixEmbeddedDriver.java:149)
> at org.apache.phoenix.jdbc.PhoenixDriver.connect(PhoenixDriver.java:221)
> at sqlline.DatabaseConnection.connect(DatabaseConnection.java:157)
> at sqlline.DatabaseConnection.getConnection(DatabaseConnection.java:203)
> at sqlline.Commands.connect(Commands.java:1064)
> at sqlline.Commands.connect(Commands.java:996)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:498)
> at
> sqlline.ReflectiveCommandHandler.execute(ReflectiveCommandHandler.java:36)
> at sqlline.SqlLine.dispatch(SqlLine.java:803)
> at sqlline.SqlLine.initArgs(SqlLine.java:588)
> at sqlline.SqlLine.begin(SqlLine.java:656)
> at sqlline.SqlLine.start(SqlLine.java:398)
> at sqlline.SqlLine.main(SqlLine.java:292)
> We can simply log a message without printing the stack trace.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)