<p>I have a Cassandra image that worked with a GKE cluster v1.0.7 but has occassional issues starting on a new GKE cluster at v1.1.1 (no changes to the image or how it is created with kubectl just pointing to a new cluster).</p>

<p>I am using kubernetes-cassandra.jar from the kubernetes Cassandra example on github.</p>

<p>I see the following in kubectl logs.</p>

<pre><code>INFO  21:57:01 Getting endpoints from https://kubernetes.default.cluster.local/api/v1/namespaces/default/endpoints/cassandra
ERROR 21:57:01 Fatal error during configuration loading
java.lang.NullPointerException: null
        at io.k8s.cassandra.KubernetesSeedProvider.getSeeds(KubernetesSeedProvider.java:129) ~[kubernetes-cassandra.jar:na]
        at org.apache.cassandra.config.DatabaseDescriptor.applyConfig(DatabaseDescriptor.java:659) ~[apache-cassandra-2.1.11.jar:2.1.11]
        at org.apache.cassandra.config.DatabaseDescriptor.&lt;clinit&gt;(DatabaseDescriptor.java:136) ~[apache-cassandra-2.1.11.jar:2.1.11]
        at org.apache.cassandra.service.CassandraDaemon.setup(CassandraDaemon.java:168) [apache-cassandra-2.1.11.jar:2.1.11]
        at org.apache.cassandra.service.CassandraDaemon.activate(CassandraDaemon.java:562) [apache-cassandra-2.1.11.jar:2.1.11]
        at org.apache.cassandra.service.CassandraDaemon.main(CassandraDaemon.java:651) [apache-cassandra-2.1.11.jar:2.1.11]
null
Fatal error during configuration loading; unable to start. See log for stacktrace.


$ kubectl get pods
NAME                         READY     STATUS             RESTARTS   AGE
cassandra                    0/1       CrashLoopBackOff   8          13m
</code></pre>

<p>Has anyone seen this error or have ideas on how to troubleshoot?</p>

<p>It happens when service endpoint is not ready. To verify that, please check output of <code>kubectl get endpoints</code> against Cassandra service. If it is blank, then it means <code>KubernetesSeedProvider</code> is not able to deserialize the output received from Kubernetes API server as the endpoint's address is in <code>notReadyAddresses</code> state.</p>

<p>One possible work-around to this problem is to create a Cassandra pod before creating Cassandra service.</p>
