[英]How to send a HttpRequest using HttpURLConnection?
I have a proxy server (JAX-RS) and I want to forward some request to an other server. 我有一个代理服务器(JAX-RS),我想将一些请求转发到另一台服务器。 I can do that, with getting the original Request, get all headers and data from it, and one-by-one set the HttpURLConnection, but it's not efficient I think.
我可以通过获取原始Request来做到这一点,从中获取所有标头和数据,并一一设置HttpURLConnection,但是我认为这样做效率不高。
Is there a way to 有没有办法
OR 要么
RequestDispatcher.forward(request)或sendredirect()方法有什么问题?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.