Mario Ishac
Mario Ishac

Reputation: 5887

Can a synchronous HTTP request be handled asynchronously on the server?

I'm trying to understand the terminology I see in other posts regarding synchronous and asynchronous web requests, so, in the below scenario:

The client sends a request synchronously to the server (meaning the client is blocked until it receives a response), and the server formulates the response asynchronously (it starts a new thread per request and creates the response on that thread).

Would the request itself be synchronous, but the handling of the request asynchronous?

Upvotes: 2

Views: 1194

Answers (1)

Filippo Mondinelli
Filippo Mondinelli

Reputation: 11

The client can be synchronous while the server is asynchronous, but this doesn't necessarily mean that the response is made on a new thread.

Figure 4-15 Figure 4-15 of this document is shown above. It depicts two cases of sync-client/async-server

Upvotes: 0

Related Questions