WealthCare is a microservice application deployed using Maven.
The application consists of the below 3 Personas.
Business Manager can do the following operations.
- Creates Wealth manager
- Creates Customer
- Assign Wealth manager to the customer
Wealth Manager can do the following operations.
- Manage financial plan for Customer
- Create Goals
- Create Investment
- View Customer Portfolio
- View Customer profile
Customer can do the following operations.
- View Financial Plan
- View Portfolio
- View Profile
The Wealthcare monolith Application is licensed under Apache-2.0 License.
- Java
- EJB
- Websphere
- DB2 database
-
- Install the below dependencies in your Openshift Environment.
sudo yum install docker
sudo yum install maven
-
- Fork the git repository and then clone it into your environment. Use you Personal Access Token if needed.
-
- Go to the below folder and build the EAR file.
ls
cd wealthcare-monolith-maven-app/config/
ls
chmod +x 01-buildEar.sh 03-build-dockerhub.sh
ls
./01-buildEar.sh
-
- Check if the OpenShift Image Registry is present in your environment.
oc get route -n openshift-image-registry
oc get route -n openshift-image-registry | awk '{print $2}' | awk 'NR==2'
# Change the path below
docker login -u $(oc whoami) -p $(oc whoami -t) <above-image-registry-path>
# Check if docker pull is successful
docker pull hello-world
-
- Create a project namespace.
cd wealthcare-monolith-maven-app/config/
oc create -f 02-namespace.yaml
oc project wealthcare-monolith-ns
-
- Build the docker hub file.
cd wealthcare-monolith-maven-app/config/
./03-build-dockerhub.sh
-
- Check if the image was successfully pulled and tagged
oc get images | grep monolith
-
- Create a MYSQL Database in the namespace.
oc new-app -e MYSQL_USER=admin -e MYSQL_PASSWORD=admin -e MYSQL_ROOT_PASSWORD=root -e MYSQL_DATABASE=BLUDB mysql:latest
oc expose service/mysql
# Get the pod name
oc get pods
# Login into the mysql pod bash
oc rsh <mysql-pod-name>
#Login as the admin user. you have to provide the password as well.
mysql -u admin -p
# Check if your database is listed and then use the same.
show databases;
use BLUDB;
# Check if any tables are listed.
show tables;
# Copy the MySQL Schema and Data from the wealthcare-monolith-maven-app/sql/ path.
# Copy the content from both the .sql files and paste in the mysql bash itself.
# Check if the tables were created and populated properly.
show tables;
select * from WCUSERS;
-9) Create a Config Map in the project namespace. Before running the command, go to the file and change the URL path (add your cluster URL) and the MYSQL connection credentials (only if you have changed the username and password for the same)
cd wealthcare-monolith-maven-app/config/
oc create -f 04-config-map.yaml
-
- Deploy the Wealthcare application using the below yaml file. Before running the command, go to the file and change the image name (add your cluster URL).
cd wealthcare-monolith-maven-app/config/
oc create -f 05-monolith.yaml
-
- Ensure if all the deployments are Running and in Ready State (1/1).
oc get all
-
- Access the console through "wealthcare-monolith-app" Route created in the namespace. You need to add the following path to the Route URL.
<route-URL>/wcareWeb/
-
- Use the below Personas to login and check for the functionalities.
1) sam / sam -------- Wealth Manager 2) harry / harry -------- Business Manager 3) sandy / sandy -------- Customer