Skip to content

Instantly share code, notes, and snippets.

@xlight05
Created April 6, 2022 04:14
Show Gist options
  • Save xlight05/1a2619365abb9e594f0c49ea30a77c50 to your computer and use it in GitHub Desktop.
Save xlight05/1a2619365abb9e594f0c49ea30a77c50 to your computer and use it in GitHub Desktop.
import ballerina/http;
listener http:Listener securedEP = new(9090);
final http:Client nettyEP = check new("http://netty:8688");
service /passthrough on securedEP {
resource function post .(http:Request req) returns http:Response|error{
return nettyEP->forward("/service/EchoService", req);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment