-$ kubectl apply --namespace coherence-demo-ns -f yaml/demo-cluster.yaml +$ kubectl apply --namespace coherence-example -f yaml/demo-cluster.yaml
You can also scale the cluster using
-$ kubectl scale coherence --namespace coherence-demo-ns primary-cluster-storage --replicas=6 +$ kubectl scale coherence --namespace coherence-example primary-cluster-storage --replicas=6
You can use kubectl get pods to view the status of the apply command and the number of replicas. diff --git a/src/main/resources/web/fragments/addOrRemoveServerK8sFederation.html b/src/main/resources/web/fragments/addOrRemoveServerK8sFederation.html index 4078092..11a3aaa 100644 --- a/src/main/resources/web/fragments/addOrRemoveServerK8sFederation.html +++ b/src/main/resources/web/fragments/addOrRemoveServerK8sFederation.html @@ -10,7 +10,7 @@ Then apply this change using
-$ kubectl apply --namespace coherence-demo-ns -f yaml/primary-cluster.yaml +$ kubectl apply --namespace coherence-example -f yaml/primary-cluster.yaml
Secondary
To scale the number of replicas to 2, update the secondary-cluster.yaml used to create the cluster and change the replicas to 2 under the storage role: @@ -19,9 +19,9 @@ Then apply this change using
-$ kubectl apply --namespace coherence-demo-ns -f yaml/secondary-cluster.yaml +$ kubectl apply --namespace coherence-example -f yaml/secondary-cluster.yamlYou can also scale the cluster using the following for the primary-cluster.
-$ kubectl scale coherence --namespace coherence-demo-ns primary-cluster-storage --replicas=6 +$ kubectl scale coherence --namespace coherence-example primary-cluster-storage --replicas=6diff --git a/src/main/resources/web/fragments/shutdown.html b/src/main/resources/web/fragments/shutdown.html index cedf7e2..9c63d8b 100644 --- a/src/main/resources/web/fragments/shutdown.html +++ b/src/main/resources/web/fragments/shutdown.html @@ -3,4 +3,4 @@
-$ kubectl delete --namespace coherence-demo-ns -f primary-cluster.yaml +$ kubectl delete --namespace coherence-example -f primary-cluster.yaml diff --git a/src/main/resources/web/fragments/shutdownFederationInK8s.html b/src/main/resources/web/fragments/shutdownFederationInK8s.html index 78c1f5a..f5f0282 100644 --- a/src/main/resources/web/fragments/shutdownFederationInK8s.html +++ b/src/main/resources/web/fragments/shutdownFederationInK8s.html @@ -3,7 +3,7 @@diff --git a/yaml/demo-cluster.yaml b/yaml/demo-cluster.yaml index 7e9c773..70d4348 100644 --- a/yaml/demo-cluster.yaml +++ b/yaml/demo-cluster.yaml @@ -11,7 +11,6 @@ spec: args: - "-Dwith.http=false" - "-Dprimary.cluster=primary-cluster" - - "-Dcoherence.metrics.legacy.names=false" ports: - name: metrics port: 9612 @@ -21,7 +20,7 @@ spec: cacheConfig: cache-config.xml metrics: enabled: true - image: coherence-demo:4.0.0-SNAPSHOT + image: coherence-demo:4.0.1-SNAPSHOT imagePullPolicy: Always replicas: 2 --- @@ -37,7 +36,6 @@ spec: heapSize: 512m args: - "-Dprimary.cluster=primary-cluster" - - "-Dcoherence.metrics.legacy.names=false" ports: - name: http port: 8080 @@ -51,6 +49,6 @@ spec: metrics: enabled: true port: 9612 - image: coherence-demo:4.0.0-SNAPSHOT + image: coherence-demo:4.0.1-SNAPSHOT imagePullPolicy: Always - replicas: 1 \ No newline at end of file + replicas: 1 diff --git a/yaml/primary-cluster.yaml b/yaml/primary-cluster.yaml index 35d5a86..7ff2cb6 100644 --- a/yaml/primary-cluster.yaml +++ b/yaml/primary-cluster.yaml @@ -16,7 +16,6 @@ spec: - "-Dsecondary.cluster=secondary-cluster" - "-Dsecondary.cluster.port=40000" - "-Dsecondary.cluster.host=secondary-cluster-storage-wka" - - "-Dcoherence.metrics.legacy.names=false" ports: - name: federation port: 40000 @@ -29,9 +28,9 @@ spec: metrics: enabled: true port: 9612 - image: coherence-demo:4.0.0-SNAPSHOT + image: coherence-demo:4.0.1-SNAPSHOT imagePullPolicy: Always - replicas: 9 + replicas: 3 --- apiVersion: coherence.oracle.com/v1 kind: Coherence @@ -48,7 +47,6 @@ spec: - "-Dprimary.cluster.host=primary-cluster-storage-wka" - "-Dsecondary.cluster=secondary-cluster" - "-Dsecondary.cluster.host=secondary-cluster-storage-wka" - - "-Dcoherence.metrics.legacy.names=false" ports: - name: http port: 8080 @@ -62,6 +60,6 @@ spec: metrics: enabled: true port: 9612 - image: coherence-demo:4.0.0-SNAPSHOT + image: coherence-demo:4.0.1-SNAPSHOT imagePullPolicy: Always replicas: 1 diff --git a/yaml/secondary-cluster.yaml b/yaml/secondary-cluster.yaml index 57a1f84..9b54792 100644 --- a/yaml/secondary-cluster.yaml +++ b/yaml/secondary-cluster.yaml @@ -17,7 +17,6 @@ spec: - "-Dsecondary.cluster=secondary-cluster" - "-Dsecondary.cluster.port=40000" - "-Dsecondary.cluster.host=secondary-cluster-storage-wka" - - "-Dcoherence.metrics.legacy.names=false" ports: - name: federation port: 40000 @@ -30,9 +29,9 @@ spec: metrics: enabled: true port: 9612 - image: coherence-demo:4.0.0-SNAPSHOT + image: coherence-demo:4.0.1-SNAPSHOT imagePullPolicy: Always - replicas: 9 + replicas: 3 --- apiVersion: coherence.oracle.com/v1 kind: Coherence @@ -49,7 +48,6 @@ spec: - "-Dprimary.cluster.host=primary-cluster-storage-wka" - "-Dsecondary.cluster=secondary-cluster" - "-Dsecondary.cluster.host=secondary-cluster-storage-wka" - - "-Dcoherence.metrics.legacy.names=false" ports: - name: http port: 8080 @@ -63,6 +61,6 @@ spec: metrics: enabled: true port: 9612 - image: coherence-demo:4.0.0-SNAPSHOT + image: coherence-demo:4.0.1-SNAPSHOT imagePullPolicy: Always replicas: 1
Delete both of the Coherence clusters using the following kubectl command:
-$ kubectl delete --namespace coherence-demo-ns -f primary-cluster.yaml +$ kubectl delete --namespace coherence-example -f primary-cluster.yaml -$ kubectl delete --namespace coherence-demo-ns -f secondary-cluster.yaml -\ No newline at end of file +$ kubectl delete --namespace coherence-example -f secondary-cluster.yaml +