Hey Nick, Sergey,

Thanks for taking a look. It was just going through a really really long HBase connection retry loop (20+ minutes!). However, even setting the retries and delays to 0 in the hbase-site.xml, the connection still takes about 3 minutes to timeout. Now I'm wondering if there is a way to fail more quickly, or to put a total timeout limit on the connection attempt? Would this involve creating a jira ticket against Phoenix?

My hbase-site.xml:

<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
<configuration>
  <property>
    <name>hbase.client.retries.number</name>
    <value>0</value>
  </property>
  <property>
    <name>hbase.client.pause</name>
    <value>0</value>
  </property>
  <property>
    <name>zookeeper.recovery.retry</name>
    <value>0</value>
  </property>
  <property>
    <name>zookeeper.recovery.retry.intervalmill</name>
    <value>0</value>
  </property>
</configuration>

- Alex

On Sat, May 23, 2015 at 12:21 AM, Sergey Belousov <sergey.belousov@gmail.com> wrote:
It definitely hangs forever from what I experienced.
It also does not allow to exit from it and only killing terminal session helps.


On Fri, May 22, 2015 at 6:13 PM, Nick Dimiduk <ndimiduk@gmail.com> wrote:
Hi Alex,

It's probably not hanging forever, but going through the -- very long by default -- HBase connection retry loop. Probably you can enabled more verbose logging and see exactly what's happening. Can you confirm this is the case and file a ticket against Phoenix at https://issues.apache.org/jira/browse/PHOENIX ? Depending on how your consuming Phoenix, the log4j.properties file is probably in the bin folder next to sqlline.py.

Thanks,
Nick

On Fri, May 22, 2015 at 1:58 PM, Alex Bedley <aeoliant@gmail.com> wrote:
Hello,

I'm wondering if there is a way to timeout a PhoenixDriver connection attempt.

For example if I run:

// invalidZkQuorum = some unreachable ip address
Connection conn = DriverManager.getConnection("jdbc:phoenix:" + invalidZkQuorum);

It just hangs forever. Is there something I can put in the Properties object to force the connection to time out? I have tried setting DriverManager.setLoginTimeout(timeout).

Thank you for your time,

- Alex