In this part, you will run the OMS application and run a script that invokes the OMS APIs.
While the application is running, vFunction collects the data required for analyzing the application.
This process is called Learning, and the result is called Measurement.
In the vFunction server UI (same screen in the “workshop-win” VM shown at the end of the setup environment section) you see two controllers with the same name (oms-controller). The one marked (A) is controlling the Java agent used for dynamic analysis, and the one marked (V) controlls the process doing static analysis which is called “Viper”
Click + next to the sentence “I want to learn using a Single controller with the Name:“, check oms-controller and click APPLY
Click Refresh viper on the left pane, then click on the + next to the sentence *“I want viper to run on the controller with the * Name:“, check oms-controller and click APPLY
Click START LEARNING at the bottom of the screen and Wait until vFunction starts collecting data from the controller (the START changes to STOP and a white shadow starts pulsating)
Go to the Azure Portal and connect to the "workshop-linux" machine using Bastion. The username is workshop and the password is vFunction2021! . In the Linux terminal do the following commands:
cd ~/oms-test-script/
for i in `seq 1000`; do ./use-apis.sh ; sleep 0.5; done
In the vFunction Server Web UI (switch back to the Windows VM) - you should see the numbers of functions, resources and services in the WebUI go up after some time
Stop the Learning by clicking STOP in vFunction Web UI. We will use a ready measurement to save time
Stop the loop calling use-apis.sh in the “workshop-linux” VM (press Ctrl+C)
We’ve seen how to start the Learning process in which vFunction collects data from a running application. The following section covers how to analyze the data and specify services.
The OMS application is deployed on a tomcat server on the Linux machine located at /opt/tomcat/latest/. To stop tomcat do: sudo bash /opt/tomcat/apache-tomcat-9.0.56/bin/shutdown.sh (or simply kill the process) To start tomcat do: sudo bash /opt/tomcat/apache-tomcat-9.0.56/bin/startup.sh