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:
저자 소개
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.
채널별 검색
오토메이션
기술, 팀, 인프라를 위한 IT 자동화 최신 동향
인공지능
고객이 어디서나 AI 워크로드를 실행할 수 있도록 지원하는 플랫폼 업데이트
오픈 하이브리드 클라우드
하이브리드 클라우드로 더욱 유연한 미래를 구축하는 방법을 알아보세요
보안
환경과 기술 전반에 걸쳐 리스크를 감소하는 방법에 대한 최신 정보
엣지 컴퓨팅
엣지에서의 운영을 단순화하는 플랫폼 업데이트
인프라
세계적으로 인정받은 기업용 Linux 플랫폼에 대한 최신 정보
애플리케이션
복잡한 애플리케이션에 대한 솔루션 더 보기
오리지널 쇼
엔터프라이즈 기술 분야의 제작자와 리더가 전하는 흥미로운 스토리
제품
- Red Hat Enterprise Linux
- Red Hat OpenShift Enterprise
- Red Hat Ansible Automation Platform
- 클라우드 서비스
- 모든 제품 보기
툴
체험, 구매 & 영업
커뮤니케이션
Red Hat 소개
Red Hat은 Linux, 클라우드, 컨테이너, 쿠버네티스 등을 포함한 글로벌 엔터프라이즈 오픈소스 솔루션 공급업체입니다. Red Hat은 코어 데이터센터에서 네트워크 엣지에 이르기까지 다양한 플랫폼과 환경에서 기업의 업무 편의성을 높여 주는 강화된 기능의 솔루션을 제공합니다.