Auto-Clustering of Instances

The AccuWeb.Cloud platform offers an on-demand automated clusterization for a number of the managed templates. Such automation drastically simplifies and quickens the introduction of a dependable manufacturing-ready cluster for your project.

Below, we’ll explore the following aspects:

  1. Supported stacks, along with details on clusterization specifics.
  2. Management of auto-clustering.
  3. Utilization of cloud scripting.

Templates with Supported Auto-Clustering

At present, the clustering feature is supported by the following templates, with plans to incorporate additional stacks in the future:

Tip: Your specific service hosting provider may offer the option to configure and implement auto-clustering for additional stacks not listed here.

Tomcat/TomEE

A highly available Tomcat/TomEE cluster is configured to distribute the workload across compute nodes, boosting performance and resilience. This setup includes session replication, context attribute replication, and cluster-wide deployment of WAR files.

Note: The Auto-Clustering feature for Tomcat and TomEE is accessible from the following stack versions:

Tomcat – 10.0.5; 9.0.45; 8.5.64; 7.0.108

TomEE – 9.0.0-M3; 8.0.5

Tomcat/TomEE

GlassFish

The GlassFish servers are set up to work together seamlessly, with session replication and load balancing already configured to optimize performance and reliability.

GlassFish

Payara

The Payara servers are connected, with session replication and load balancing already configured to ensure smooth operation and optimize performance.
Payara

Jenkins

Within Jenkins, there’s a master node operating in master-slave mode. It’s equipped with auto-scalable Java Engine workers and comes with pre-installed plugins. These plugins support automation for building and deploying, enabling the organization of continuous integration (CI) and continuous delivery (CD) pipelines.

Jenkins

WildFly

The WildFly nodes operate in Domain Mode with clustering enabled, ensuring high availability and continuous performance for deployed Java EE applications.

WildFly

MySQL

Auto-Clustering is available for MySQL versions 5.7.x and 8.x exclusively.

The automatic clusterization of databases includes pre-configured replication and auto-discovery of nodes.

You have the option to choose from the following schemes based on your requirements:

1. Primary-Primary with Extra Secondaries: This scheme features pre-configured replication with two interconnected primary databases. As the cluster scales horizontally, additional secondary nodes are seamlessly integrated.

MySQL Primary-Primary

2. Primary-Secondary with Extra Secondaries scheme entails pre-configured replication with one primary and one secondary database. As the cluster scales horizontally, additional secondary nodes are seamlessly integrated.

MySQL Primary-Secondary

Learn more: https://github.com/jelastic-jps/mysql-cluster

MariaDB

Auto-Clustering is exclusively available for MariaDB versions 10.x.

The automatic clusterization of databases includes pre-configured replication and auto-discovery of nodes.

You can choose from the following Scheme types based on your requirements:

1. Primary-Primary with Extra Secondaries: This scheme features pre-configured replication with two interconnected primary databases. As the cluster scales horizontally, additional secondary nodes are seamlessly integrated.

MariaDB Primary-Primary

2. Primary-Secondary with Extra Secondaries: This scheme involves pre-configured replication with one primary and one secondary database. During horizontal scaling, the cluster expands with additional secondary nodes.

MariaDB Primary-Secondary

3. Galera Cluster: In this setup, all servers can accept updates concurrently, even if issued simultaneously.

Galera Cluster

Percona

The automatic clusterization of databases includes pre-configured replication and auto-discovery of nodes.

Based on your requirements, you have the option to select from the following scheme types:

1. Primary-Primary with Extra Secondaries: This scheme entails pre-configured replication with two interconnected primary databases. As the cluster scales horizontally, additional secondary nodes are seamlessly integrated.

Percona Primary-Primary

2. Primary-Secondary with Additional Secondaries: This configuration involves pre-configured replication with one primary and one secondary database. As the cluster expands horizontally, additional secondary nodes are seamlessly incorporated.

Percona Primary-Secondary

Moreover, you have the option to utilize the XtraDB Cluster, a robust database clustering solution designed to ensure high availability, mitigate risks of downtime and data loss, and provide linear scalability to support a growing environment.

XtraDB Cluster

PostgreSQL

A pre-configured PostgreSQL database cluster is established with asynchronous primary-secondary replication, allowing for the automatic addition of new nodes into the cluster as secondaries.

PostgreSQL

Couchbase

The Couchbase servers are automatically interconnected with pre-configured auto-scaling and rebalancing, ensuring a unified, highly available data storage system.

Couchbase

Learn more: https://github.com/jelastic-jps/couchbase

MongoDB

Automatically configure a highly-available and reliable MongoDB replica set, complete with auto-discovery of new nodes for seamless integration.

MongoDB

Redis

Automatization is provided for the distributed implementation of a Redis Cluster, an open-source, in-memory data structure store. Typically used for caching, data storage, acting as a message broker, and various other tasks. The topology includes a minimum of three Primary servers, each accompanied by a Secondary node to facilitate read load distribution and auto-recovery in case of Primary server failure.

Redis

OpenSearch

Automatic clustering of a community-driven, open-source search engine that offers distributed, multitenant full-text search. The solution has built-in options for integrating OpenSearch Dashboards for data visualization and Logstash for log processing.

OpenSearch

Shared Storage Container

The AccuWeb.Cloud platform automatically configures a dependable storage cluster using the Gluster solution, guaranteeing data safety. In the event of node failure, the AutoFS client seamlessly switches to operational instances, ensuring high availability of storage resources.

Shared Storage Container

Save $100 in the next
5:00 minutes?

Register Here

Auto-Clustering Management

1. The Auto-Clustering feature can be activated for the node group using the corresponding switcher located in the central part of the topology wizard, provided it is available for the selected stack.

Auto-Clustering Off

Tip: Depending on the specific implementation, the Auto-Clustering option may vary:
I. It could be mandatory, requiring automatic activation (e.g., for the Couchbase database).Auto-Clustering On

II. It may be mandatory with additional settings available (e.g., cluster scheme and ProxySQL load balancer for the MySQL database).

Cluster scheme and ProxySQL load balancer

III. It might come with restrictions, such as minimum/maximum node counts or scaling modes (e.g., for the MariaDB Galera type).

Node counts

2. Additionally, to obtain further details about the cluster being created, hover over the question mark icon adjacent to the switcher. In the resulting pop-up frame, you’ll find a brief description, often accompanied by a topology scheme and a link to a more comprehensive overview.

Question Mark Icon

For details on different database cluster types, click on the corresponding “Scheme“:
Scheme

3. Other settings can be configured similarly to any regular environment.

Configure

Note: Once configured, auto-clustering cannot be disabled from the topology wizard.

4. If necessary, you can monitor the cluster configuration logs through the platform console at:

https://app.{platformDomain}/console

Platform Console

For example, this information can be used for debugging purposes when developing packaged solutions with Cloud Scripting, which make use of the auto-clustering feature.

Save $100 in the next
5:00 minutes?

Register Here

Setting Up Auto-Clusterization with Cloud Scripting

To define auto-clustering settings in your JPS solutions, you can use a new cluster property. Here’s how you can do it:

1. Use the relevant cluster property to enable or disable auto-clustering for the specific layer.


"nodeGroup": "couchbase",
"cluster": true | false

2. Provide additional parameters for auto-clustering, such as selecting a database cluster scheme, by specifying them in the cluster property.


"nodeGroup": "mysql",
"cluster": {
"scheme": "master"
}

3. If necessary, substitute the default JPS manifest with a custom one that includes the desired clusterization steps.


"nodeGroup": "mysql",
"cluster": {
"jps": "http://.../custom-manifest.jps",
"settings": {
"scheme": "master"
}
}

4. Depending on the specific cluster requirements, you may need to impose certain topology restrictions, such as defining the minimum/maximum number of nodes or the scaling mode. This can be implemented through the validation property.

You can specify these parameters for any JPS package. Here’s an example in YAML format:


type: install
name: Validation
nodes:
 image: alpine
 nodeGroup: cp
 count: 2
 validation:
   minCount: 2
   maxCount: 3
   scalingMode: stateful

With these steps, you can easily leverage the auto-clustering solutions supported by the AccuWeb.Cloud platform and benefit from their implementation specifics.

Save $100 in the next
5:00 minutes?

Register Here