Author: Payal Jain
Introduction:
CloudHub 2.0 simplifies the deployment and running of the MuleSoft application in a containerized environment, based on the Kubernetes. It provides for deployments across 12 regions globally.
Why Cloudhub 2.0:
- There is no need to manage a dedicated load balancer as CloudHub 2.0 provides a built-in Ingress load balancer with auto-scaling capabilities in the private space.
- We have the option to configure inbound and outbound firewalls. This enables us to block or allow traffic from specific ports.
- We are provided with built-in security policies that secure the services and sensitive data with encrypted secrets.
- Cloudhub 2.0 vs Cloudhub 1.0-
CloudHub 1.0 | CloudHub 2.0 | |
Provision/Scaling | Supported | Supported |
URL rewriting | Support (DLB) | Supported (app-level) |
Load Balancer Logs | Not supported | Supported (download) |
Multiple custom endpoints | Partially Supported | Supported |
Multiple truststores (client certificates for mutual TLS) | Not supported | Supported |
Direct Connect/VPC Peering | Supported (not self-serve) | Not Supported |
VPC/VPN/Transit Gateway | Supported | Supported (private spaces) |
Outbound firewall rules | Not supported | Supported |
Log forwarding | Supported (per app) | Supported (per app) |
Custom notifications (CloudHub Connector) | Supported | Not Supported |
- Implementation steps needed in pom.xml for deployment are as follows-
- In the Mule project, in pom.xml we need to make sure our Mule maven plugin version is 3.7.1 or above for deployment to CloudHub 2.0.
- We must also add the necessary “configuration” details for CloudHub 2.0 in the pom.xml file.
<mule.maven.plugin.version>3.7.1</mule.maven.plugin.version>
<configuration>
<cloudhub2Deployment>
<uri>https://anypoint.mulesoft.com</uri>
<provider>MC</provider>
<environment>Sandbox</environment>
<target>Cloudhub-US-East-2</target>
<username>${anypoint.username}</username>
<password>${anypoint.password}</password>
<applicationName>cloudhub2-test</applicationName>
<businessGroupId>**********-e628</businessGroupId>
<replicas>1</replicas>
<vCores>0.1</vCores>
</cloudhub2Deployment>
<classifier>mule-application</classifier>
</configuration>
- We can publish to Exchange through Anypoint Studio with Project Type set to Example.

- We can verify this from Exchange.

- Open the command prompt in the project location, where pom.xml is present. Run the below maven command to deploy the application.
mvn clean package deploy -DmuleDeploy -Danypoint.username=<username> -Danypoint.password=<password>
- This shall give us Build Success and we can check the Running status in Runtime Manager on the Anypoint platform.

NOTE: Common Issues faced during deployment –
- GAV could not be retrieved from Exchange – Bad Request
GAV stands for – GroupId, ArtifactId, VersionId.
Resolution – The publish to Exchange step is necessary for Cloudhub 2.0 Deployment.

- Configuration is invalid while building-
Resolution: Check for Mule maven plugin version to be 3.7.1 or higher version.