After you deploy a virtual service (virtual API) to VirtServer, you may need to modify the virtual service functionality. On VirtServer, you can modify the port your service uses. Deeper changes to your service functionality, for example, adding a new operation, require that you have the virtual service on your computer.
|For information on when you need to download the Vert and when you can skip downloading, see below.|
In ReadyAPI, select the ServiceV node in the Navigator panel and connect to your VirtServer (see Connect With ServiceV).
In the VirtServer section of the ServiceV editor, right-click your virtual service and select Download from the context menu. See also Virtual Services Page in ServiceV.
If you have the virtual service on your computer, ReadyAPI will ask you whether you want to replace the existing virtual service with the downloaded copy:
You have the following options:
Create a new project
Keeps the local virtual service. Creates a new project and copies the service along with the data files it uses from VirtServer to your computer.
Since the virtual service is placed in the new project, ReadyAPI sees it as a new service. If you deploy this service to VirtServer, it will not replace the existing service there, it will create a “new” service on VirtServer.
Replace old virtual service
Replaces the exiting local virtual service with the service from VirtServer.
Cancels the download.
When the virtual service is on your computer, click the service in the Local Virtual Services section of the ServiceV editor and modify its properties on the left.
You can also right-click the service and select Show Virtual Service Editor from the context menu. To switch to the virtual service editor, you can also simply select your service in the project tree on the left.
After you update the virtual service, you can upload it back to VirtServer. To do this:
In ServiceV, select the desired VirtServer, and
Drag the service from the Local Virtual Services section.
See also Virtual Services Page in ServiceV.
You need to download the virtual service to your computer if –
You do not have the virtual service on your machine, or
The deployed service was changed on VirtServer by somebody. In this case, if you download the service, you can be sure that you will not override the changes made by others.
You can skip downloading the virtual service if –
You have the virtual service on your computer, and
You are sure that nobody has changed the virtual service on VirtServer after you deployed it there.
If you are going to work on the functionality of your virtual service along with your co-workers, we do not recommend using VirtServer as a place for sharing the virtual service. Use a source control system instead.
Virtual service settings are stored as part of a ReadyAPI project. So, you can put your ReadyAPI project to a source control repository and work with the project in the same way you work with other files placed in source control repositories.