Welcome back.

In our last video, we talked about Parasoft Virtualize Message Proxies and what their purposes were. In this video, we're going to discuss Monitoring Traffic. Getting started. I'm going to show you how to configure the Parabank demo app and use a proxy to record from our demo application.

We will also discuss monitoring of that proxy. So, let's go ahead and start taking a look at the endpoints of our demo application. We get here by going to our Services section here. The service we are going to be recording today is a Loan Processor Service. So I'm going to scroll down and find that. It is a third-party dependency that we have in our application.

We want to go ahead and record the information that is sent to it and create the virtual service for it. The first thing we're going to need is the actual endpoint of the service. You can find that right here in the UI. So let's go ahead and copy this and we can add to the connection information of our proxy. So then we can come back into Virtualize and we can go to the proxy here and we can see this.

So, let's click Add and we will put the endpoint service in the primary connection. This means that when we connect to the proxy, it will forward its information to this endpoint. Now, what we have to do is to find the endpoint for the proxy to listen to.

We recommend using the information you have for the real service by adding a little information. So, you know it's a proxy.

So, I'm just going to add a proxy here to the proxy listening path. And that is really all I need for this case because when I go to start recording, it's going to take all calls from this endpoint and it's going to forward them to this endpoint while recording this information into a traffic file. So if you're following along, I would recommend grabbing your proxy endpoint because we'll be using that in just a moment.

So now we're going to click Okay. And now we're going to name this proxy. In this case, this is the Loan Processor Proxy. And then click Save. And now, most importantly, we want to go to the proxy here. And we want to make sure that we enable it. Now that this proxy exists and more importantly, we have copied it to our clipboard. What we should do now is feed that proxy URL to our demo application so that it knows to connect to our proxy to send the call back to the third-party service.

Now, let's go ahead and bring up the demo application. And you'll see at the very top, you're going to have this Admin Page. We're going to click on that. One of the things that you will see is a loan processor service endpoint here.

So we're going to click Paste, and click Submit. Now we have just told the demo application, whenever you connect to the third-party service, loan process for service, connect to the proxy instead, that means all calls will be redirected to the proxy and the proxy will be redirected back to the correct service. So, let's go ahead and test this out. The best way to use a proxy in Parasoft Virtualize Free Edition is to view the transactions that are flowing through it.

So, if we go back into the Virtualize application, we right-click on the Loan Proxy and we can click Start Monitoring. What this means is now any transactions that go through the proxy will be sent to the Virtualize event detail framework. We can go ahead and look at the event details framework by clicking on the Open Perspective button at the very top of the solution and choosing Parasoft Event Details. So Parasoft Event Details, click Open. You will see that this opens up into the Event Details framework, and when we start exercising that proxy, we will see the data come through and we will see the events.

So to exercise this third-party service, we need to apply for a loan. Since this is a loan processing service. So, we're going to go back into our Parabank demo app. And if we click on the logo, it's going to take us back to the homepage, and we can log in. The login credentials for Parabank are John, all lowercase, and demo is the password. We're going to click Login. What we can do now is select the Request Loan function. I'm going to put in a small loan amount here of about $1,000, with a down payment of $10 and I'm going to click Apply now. It will try to connect with the back-end service. And it looks like everything was successful.

The real information we'll see once we look at Virtualize. I will see all the details that are actually being sent through my proxy. It is not only important to know that we will be able to record this transaction in a moment. It will also be important if we ever need to debug the service we see here, that we receive those requests, and those requests will forward to the real system.

The real system responded and we got our response back. Now we are in a position we can start recording the transactions from our application and create a virtual service. And that is exactly what we going to do in our next video.

Up next, Creating Virtual Services from Recorded Traffic. 

Comments are closed.

{"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}