github.com/qsunny/k8s@v0.0.0-20220101153623-e6dca256d5bf/examples-master/cassandra/java/README.md (about)

     1  # Cassandra on Kubernetes Custom Seed Provider: releases.k8s.io/HEAD
     2  
     3  Within any deployment of Cassandra a Seed Provider is used for node discovery and communication.  When a Cassandra node first starts it must discover which nodes, or seeds, for the information about the Cassandra nodes in the ring / rack / datacenter.
     4  
     5  This Java project provides a custom Seed Provider which communicates with the Kubernetes API to discover the required information.  This provider is bundled with the Docker provided in this example.
     6  
     7  # Configuring the Seed Provider
     8  
     9  The following environment variables may be used to override the default configurations:
    10  
    11  | ENV VAR       | DEFAULT VALUE  | NOTES |
    12  | ------------- |:-------------: |:-------------:|
    13  | KUBERNETES_PORT_443_TCP_ADDR   | kubernetes.default.svc.cluster.local  | The hostname of the API server   |
    14  | KUBERNETES_PORT_443_TCP_PORT   | 443                                   | API port number                  |
    15  | CASSANDRA_SERVICE              | cassandra                             | Default service name for lookup  |
    16  | POD_NAMESPACE                  | default                               | Default pod service namespace    |
    17  | K8S_ACCOUNT_TOKEN 		 | /var/run/secrets/kubernetes.io/serviceaccount/token | Default path to service token |
    18  
    19  # Using
    20  
    21  
    22  If no endpoints are discovered from the API the seeds configured in the cassandra.yaml file are used.
    23  
    24  # Provider limitations
    25  
    26  This Cassandra Provider implements `SeedProvider`. and utilizes `SimpleSnitch`.  This limits a Cassandra Ring to a single Cassandra Datacenter and ignores Rack setup.  Datastax provides more documentation on the use of [_SNITCHES_](https://docs.datastax.com/en/cassandra/3.x/cassandra/architecture/archSnitchesAbout.html).  Further development is planned to
    27  expand this capability.
    28  
    29  This in affect makes every node a seed provider, which is not a recommended best practice.  This increases maintenance and reduces gossip performance.
    30  
    31  
    32  <!-- BEGIN MUNGE: GENERATED_ANALYTICS -->
    33  [![Analytics](https://kubernetes-site.appspot.com/UA-36037335-10/GitHub/examples/storage/cassandra/java/README.md?pixel)]()
    34  <!-- END MUNGE: GENERATED_ANALYTICS -->