This tutorial shows you how to run Apache OFBiz on Alibaba Cloud with ApsaraDB RDS for MySQL.
You can access all the tutorial resources, including deployment script (Terraform), related source code, sample data, and instruction guidance, from the GitHub project: https://github.com/alibabacloud-howto/opensource_with_apsaradb/tree/main/apache-superset
For more tutorials around Alibaba Cloud Database, please refer to: https://github.com/alibabacloud-howto/database
Apache OFBiz is an open source enterprise resource planning (ERP) system. It provides a suite of enterprise applications that integrates and automates many of the business processes of an enterprise.
To enhance Apache OFBiz with a high availability database, we will show you the steps of deploying and working with Alibaba Cloud ApsaraDB RDS for MySQL database.
By default OFBiz includes and is configured for an embedded Java database called Derby. This is a great database for demos, testing, development, and even small-scale production environments. There are many databases that OFBiz can use, both commercial and open source.
While there are significant production instances of OFBiz running using Oracle, MS SQL Server, and so on, we generally recommend using an open source database such as PostgreSQL or MySQL. The choice of database is an important decision and may have future impacts on your implementation. If you do not have a preferred database choice then we strongly recommend discussing options with an experienced consultant before making a final decision.
In this tutorial, we will show the case of using RDS MySQL high availability edition to replace the Derby for more stable production purpose.
Run the terraform script to initialize the resources (in this tutorial, we use RDS MySQL as backend database of OFBiz, so ECS and RDS MySQL instances are included in the Terraform script). Please specify the necessary information and region to deploy.
After the Terraform script execution finished, the ECS and RDS MySQL instance information are listed as below.
Please log on to ECS with
Then execute the following commands to setup the Apache OFBiz.
wget https://raw.githubusercontent.com/alibabacloud-howto/opensource_with_apsaradb/main/apache-ofbiz/setup.sh sh setup.sh
After the setup script execution finished, go to edit the property
security.properties file to add the host IP of the ECS:
cd ofbiz-framework vim framework/security/config/security.properties
Then edit the
entityengine_backup.xml configuration file to set the backend database as RDS MySQL to replace the Derby. Edit with the RDS MySQL connection string and database accounts as shown in the following pictures.
cp framework/entity/config/entityengine.xml framework/entity/config/entityengine_backup.xml vim framework/entity/config/entityengine.xml
Replace Derby with RDS MySQL in
test delegators as follows:
Execute the following command to build and initialize the OFBiz.
./gradlew cleanAll loadAll
Execute the following command to start the OFBiz.
OFBiz now started. Please visit the following URL to visit the OFBiz now.
By default, the administrator account name is
admin, password is
ApsaraDB - September 8, 2021
ApsaraDB - September 23, 2021
Alibaba Clouder - December 18, 2017
ApsaraDB - September 7, 2021
Alibaba Clouder - February 13, 2019
Alibaba Clouder - February 21, 2020
An on-demand database hosting service for MySQL with automated monitoring, backup and disaster recovery capabilitiesLearn More
Fully managed and less trouble database servicesLearn More
A fully-managed Apache Kafka service to help you quickly build data pipelines for your big data analytics.Learn More
An on-demand database hosting service for MySQL, SQL Server and PostgreSQL with automated monitoring, backup and disaster recovery capabilitiesLearn More
More Posts by ApsaraDB