Paul Edwards created THRIFT-3450:
------------------------------------

             Summary: NPE when using SSL
                 Key: THRIFT-3450
                 URL: https://issues.apache.org/jira/browse/THRIFT-3450
             Project: Thrift
          Issue Type: Bug
          Components: Java - Library
    Affects Versions: 0.9.3, 0.9.2
         Environment: Linux
            Reporter: Paul Edwards


When running version 0.9.2 or 0.9.3 of libthrift to access cassandra, I'm 
getting a NPE:

Caused by: java.lang.NullPointerException
        at 
org.apache.thrift.transport.TSSLTransportFactory$TSSLTransportParameters.<init>(TSSLTransportFactory.java:312)
        at 
org.apache.thrift.transport.TSSLTransportFactory$TSSLTransportParameters.<init>(TSSLTransportFactory.java:297)
        at 
me.prettyprint.cassandra.connection.security.SSLHelper.getTSSLTransportParameters(SSLHelper.java:36)
        at 
me.prettyprint.cassandra.connection.factory.HThriftClientFactoryImpl.createClient(HThriftClientFactoryImpl.java:28)
        at 
me.prettyprint.cassandra.connection.ConcurrentHClientPool.createClient(ConcurrentHClientPool.java:173)
        at 
me.prettyprint.cassandra.connection.ConcurrentHClientPool.<init>(ConcurrentHClientPool.java:58)
        at 
me.prettyprint.cassandra.connection.RoundRobinBalancingPolicy.createConnection(RoundRobinBalancingPolicy.java:68)
        at 
me.prettyprint.cassandra.connection.HConnectionManager.<init>(HConnectionManager.java:68)
        at 
me.prettyprint.cassandra.service.AbstractCluster.<init>(AbstractCluster.java:67)
        at 
me.prettyprint.cassandra.service.ThriftCluster.<init>(ThriftCluster.java:21)
        at 
me.prettyprint.hector.api.factory.HFactory.createCluster(HFactory.java:197)
        at 
me.prettyprint.hector.api.factory.HFactory.getOrCreateCluster(HFactory.java:144)
        at 
com.contextspace.dao.impl.TransactionManager.afterPropertiesSet(TransactionManager.java:62)
        at 
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1514)
        at 
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1452)
        ... 114 more


If I downgrade libthrift to version 0.9.1 then it all happily connects. I was 
wondering whether this was related to: 
https://issues.apache.org/jira/browse/THRIFT-2122 but I can't see any reason it 
should be. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to