Stubbing settings for Istio stubs
You can specify the stubbing settings depending on the Message Exchange Pattern defined for the HTTP transport.
Before you begin
You must have completed the following tasks:
- Created a logical connection. See Creating logical HTTP connections.
- Created an HTTP transport with a Web Server as the physical resource. See Creating physical web server resources.
- Defined a service component. See Creating a service component.
- Created an operation under the service component. See Creating an operation.
About this task
You can create stubs for the following types of requests received or sent by the Istio service mesh:
- Requests received by services in the Istio service mesh.
- Requests sent from namespaces in the Istio service mesh to external services that are not in the Istio service mesh.
Procedure
-
Double-click the operation in the Logical View tab of Architecture School perspective.
The Operation dialog is displayed.
-
Click the Stub tab.
The Stub tab is displayed.
-
Complete the following steps to select a transport:
- Select the message type as Text in the Message Type field.
-
Complete the following steps in the Property Filters tab, if required:
-
Complete the following steps in the Header Filters tab, if required:
- The Default Timeout section contains common settings for stub replies. No change is required. The response time is managed by the stubs execution engine in HCL OneTest™ API.
- Click OK to save the stubbing settings.
Results
You have configured the stubbing settings for an operation.
What to do next
You can create a stub by using MEP from the Test Factory view. See Creating a stub by using MEP.
After you create the stub that virtualizes a service in the Kubernetes cluster, you can perform the following actions:
- Publish the stubs to Istio. See Publishing stubs to Istio.
- After publishing the stubs, you can run the stubs on Istio. See Running stubs in Istio or Kubernetes.Note: You cannot run the stubs on HCL OneTest™ API.
- You can add the stubs to a project on HCL OneTest™ Server, and then run the stubs from the Execution page. Refer to the HCL OneTest™ Server documentation.