MuleSoft’s Anypoint Platform is an Integration and API management platform. Anypoint Runtime Fabric (RTF) is a container service that automates the deployment and orchestration of Mule applications. With the release of the certified MuleSoft Runtime Fabric Operator, MuleSoft customers have the option of deploying their containerized workloads anywhere OpenShift can be deployed - whether it is on-prem, or on a public cloud of their choice (either as Red Hat managed or self managed).
Mule workloads on OpenShift
The objective of this blog post is to show customers the value of running Mule workloads on OpenShift. We show how to deploy Mule workloads on OpenShift using the certified MuleSoft Runtime Fabric (RTF) Operator. As an example, we deploy a Mule application on OpenShift to send JSON data over to Active MQ broker which is also deployed on OpenShift.
Installation of MuleSoft Anypoint Runtime Fabric (RTF) instance
Below is a high level diagram which summarizes the creation of RTF instance on OpenShift.
Prerequisites
You will need an enterprise MuleSoft account to have access to Runtime Fabric from Runtime Manager. With that enterprise account, from https://anypoint.mulesoft.com/ Anypoint platform, navigate to the Runtime Manager and then you will be able to create a Runtime Fabric instance.
Your MuleSoft account representative will help you acquire an Enterprise license in the form of a licence.lic file which will be needed for creating an RTF instance.
Have a running OpenShift cluster ready - whether it is on prem or on a public cloud.
Once you have the above prerequisites in place, follow the instructions listed on https://anypoint.mulesoft.com/cloudhub/#/console/home/runtimefabrics/list and create a Runtime Fabric by selecting "OpenShift" as the installation platform.
Then navigate to the Operator hub in the OpenShift cluster and install the RTF Operator. After the RTF Operator is installed, navigate to the Runtime Fabric namespace. Use the form view to create a RTF instance.
Fill the RTF instance form view with activation data from the Anypoint Runtime Fabric page, base64 encoded format of the license from the enterprise mule license file.
https://github.com/gskumar1010/mule-rtf-openshift/blob/main/installing-rtf-openshift/README.md has additional details with screenshots.
Create a Service account which can be used for running the RTF instance.
Before creating the RTF instance, toggle to the yaml view and add the service account. Then create the RTF instance.
Once all the pods in the “rtf” namespace are active and registered with Anypoint platform, in under 5 minutes the Runtime Fabric will become active in Anypoint platform.
From the above github repo, copy the ingress template yaml into your OpenShift cluster, modify the hostname by providing appropriate value and create an ingress. This will create an ingress in the “rtf” namespace. All Mule applications for this RTF instance will use this ingress.
Deploying example application
For this deployment, we are using the example from Anypoint Exchange. We customized it to connect to an Active MQ Broker running on OpenShift. Mule flow kicks in by receiving a HTTP request for Sales Data, converting it to JSON, and sending it to “Sales” Queue on Active MQ. These messages can then be viewed on the Admin console deployed using OpenShift routes.
Below is a high level diagram which summarizes the above example.
Prerequisites
- Download the JAR file for this example, from https://github.com/gskumar1010/mule-rtf-openshift/tree/main/mule-examples
- To run the application as is, log into your Anypoint platform, and go to your RTF instance created. Refer to above section for RTF installation.
- Make sure to have an Active MQ Broker running. More information can be found at https://access.redhat.com/documentation/en-us/red_hat_amq/7.7/html/deploying_amq_broker_on_openshift/index
Once you have the above prerequisites in place, click “Deploy Application” and fill in details as shown below in your Anypoint Runtime Manager, under “Applications”. Make sure to select the RTF instance in the Target section, and upload the previously saved JAR from the above step.
Go ahead and fill in the properties section, Active MQ details for your broker. Note that you can mask sensitive information. Once deployed, you should see the application as shown below. Allow a few minutes for RTF to connect to Openshift Instance and deploy the application.
Go to your OpenShift project created by RTF, and validate that the application pod, corresponding services/routes are created successfully.
OpenShift routes expose the http endpoint to the outside world, and we can test this endpoint by using CURL or Postman client.
Externalizing properties
In this example, to expose above http and Active MQ connection properties, configuration.xml has been updated as shown below in the Mule application.
Above properties, will reflect as Config Map and Secrets on OpenShift project.
Testing Mule Application
Once deployed successfully, we should be able to send a message to the HTTP endpoint exposed by the OpenShift route, and the message gets published to Active MQ “sales” queue successfully.
You should now see the published message on the “sales” queue on the Active MQ Admin console.
Conclusion
In this article, we discussed the value of running Mule workloads on OpenShift. We showed how to install Anypoint Runtime Fabric on OpenShift and deployed an example application.
You can work with a trusted ecosystem of system integrator partners like IBM, Accenture, Deloitte, CapGemini, and PWC who provide expertise in implementing MuleSoft and OpenShift platforms.
Please reach out to your alliance contacts or account teams from Red Hat or MuleSoft for more information.
Reference:
Sobre os autores
With his experience of being a customer of OpenShift as well as prior experience of working on IBM software, Santosh helps customers with their Hybrid Cloud adoption journey.
Navegue por canal
Automação
Últimas novidades em automação de TI para empresas de tecnologia, equipes e ambientes
Inteligência artificial
Descubra as atualizações nas plataformas que proporcionam aos clientes executar suas cargas de trabalho de IA em qualquer ambiente
Nuvem híbrida aberta
Veja como construímos um futuro mais flexível com a nuvem híbrida
Segurança
Veja as últimas novidades sobre como reduzimos riscos em ambientes e tecnologias
Edge computing
Saiba quais são as atualizações nas plataformas que simplificam as operações na borda
Infraestrutura
Saiba o que há de mais recente na plataforma Linux empresarial líder mundial
Aplicações
Conheça nossas soluções desenvolvidas para ajudar você a superar os desafios mais complexos de aplicações
Programas originais
Veja as histórias divertidas de criadores e líderes em tecnologia empresarial
Produtos
- Red Hat Enterprise Linux
- Red Hat OpenShift
- Red Hat Ansible Automation Platform
- Red Hat Cloud Services
- Veja todos os produtos
Ferramentas
- Treinamento e certificação
- Minha conta
- Suporte ao cliente
- Recursos para desenvolvedores
- Encontre um parceiro
- Red Hat Ecosystem Catalog
- Calculadora de valor Red Hat
- Documentação
Experimente, compre, venda
Comunicação
- Contate o setor de vendas
- Fale com o Atendimento ao Cliente
- Contate o setor de treinamento
- Redes sociais
Sobre a Red Hat
A Red Hat é a líder mundial em soluções empresariais open source como Linux, nuvem, containers e Kubernetes. Fornecemos soluções robustas que facilitam o trabalho em diversas plataformas e ambientes, do datacenter principal até a borda da rede.
Selecione um idioma
Red Hat legal and privacy links
- Sobre a Red Hat
- Oportunidades de emprego
- Eventos
- Escritórios
- Fale com a Red Hat
- Blog da Red Hat
- Diversidade, equidade e inclusão
- Cool Stuff Store
- Red Hat Summit