Configure the HTTP/HTTPS Gateway Agents

Supported for: Windows and Linux

This task describes how to configure the Service Virtualization HTTP/HTTPS gateway agents.

The HTTP/HTTPS Gateway Agents serve to virtualize HTTP communication. A virtual HTTP endpoint is created to mediate between a client and a real service HTTP endpoint. During the learning process, real communication is forwarded to a real service HTTP endpoint and the communication is recorded.

To configure the HTTP/HTTPS Gateway agents

  1. Configure the agent settings

    From the main menu, select Tools > Options. On the Agents Page, select HTTP Gateway or HTTPS Gateway. For user interface details, see HTTP/HTTPS Gateway Agent Settings.

  2. Forward unknown endpoint requests

    If you are not able to reconfigure clients on a service basis (i.e. changing the endpoint of each service to a virtual service), and all of your HTTP(S) services reside on a single host, you can use the Forwarded to Host option on the Agents Page.

    Example: The client is calling several backend services:

    http://esb.demo.hpe.com:8080/BackendServices/MemberAccounts
    http://esb.demo.hpe.com:8080/BackendServices/ExchangeRate
    http://esb.demo.hpe.com:8080/BackendServices/Approval

    You are only virtualizing the MemberAccounts service but are only able to reconfigure the application to use another host for all services rather than changing the endpoint of just the one MemberAccounts service in the application.

    You reconfigure your application to use the SV Server HTTP Gateway at:

    http://svserver.hpe.com:7200 instead of http://esb.demo.hpe.com:8080

    The application will access backend services at these endpoints:

    http://svserver.hpe.com:7200/BackendServices/MemberAccounts
    http://svserver.hpe.com:7200/BackendServices/ExchangeRate
    http://svserver.hpe.com:7200/BackendServices/Approval

    You create the MemberAccounts service so this functions but the other services would be inaccessible for the application until you virtualized all of them.

    To avoid the virtualization of all backend services set the DEFAULT TARGET HOST to

    http://esb.demo.hpe.com:8080

    Now all requests to non-virtualized services are forwarded to the http://esb.demo.hpe.com:8080 host and are reaching the real services you do not intend to virtualize now.

    Note: The Forwarded to Host field can contain a base URL in several formats: the host, optional port, and optional base path, i.e.: http://esb.demo.hpe.com, http://esb.demo.hpe.com:8080.
  3. Configure a proxy agent

    To set the proxy agent configuration properties, see Configure the HTTP(S) Proxy Agent.