Two java services, connected using http long connection, pushed from service one to service two. I would like to ask, how should the two services be implemented?
Thanks
ringa_lee2017-06-28 09:24:59
Correction
Just checked
In fact, if you use the latest HTTP components, they can already optimize this problem by themselves
Feign uses the JDK's native URLConnection to send HTTP requests by default. There is no connection pool, but a long connection is maintained for each address, that is, the persistence connection of HTTP is used. We can replace Feign's original http client with Apache's HTTP Client to gain control over performance such as connection pools and timeouts. Spring Cloud supports this replacement starting from Brixtion.SR5 version. First declare Apache HTTP Client and feign-httpclient dependencies in the project
`