I am developing an application using Jaxb. XMl Resides at the server side and communication needs to be there between server and client.
What application needs to do(Rqmt. Specified):-> To send a request and receive a response, an application obtains a TCP connection and uses HTTP POST. That is, the request is sent in the HTTP POST request body and the response is received in HTTP POST response body. Because there can be multiple request/response transactions occurring simultaneously, such connections can coexist in time, although eventually each is torn down. To receive indications, the client obtains one connection and starts a HTTP GET request to the server. The server returns an HTTP1.1 chunked stream of data. Each chunk of the stream corresponds to an indication sent from the server to the client application. The GET request never ends, so effectively it is a permanent TCP connection. This connection is not torn down unless the application exits or the connection is broken.
Should I use apache HTtPClient or any other api? How to achieve contineous get response?