I have a use case where I am running the Karate Netty server as a forward proxy server to forward requests to a target Tomcat server. I noted that the hostname header gets set to the Karate Netty Server while forwarding the request which causes the request to not give a response. Can we somehow please update the request header before forwarding the request to target server.
Broader Use Case: Testing in live QA environment where we have a lift and shift project to move our rest services from one infrastructure platform to another infrastructure platform. Here is sample feature file:
Feature:
Scenario: pathMatches('/myresources/getResource') && methodIs('GET')
# Sending request to PLATFORM ABC URL
* karate.proceed('http://localhost:8081')
* def response1 = response
# Sending request to PLATFORM XYZ URL
* karate.proceed('http://localhost:8082')
* def response2 = response
* match response1 == response2