V
V
Vova2022-03-16 00:03:17
Computer networks
Vova, 2022-03-16 00:03:17

Can you help me find 10 differences between "web servers"?

Hello.
Background.
I needed to write tests for one application.
The application is a crash reporter. It grabs a dump from the disk and sends it to the given url.
Inside the crash reporter, as I understand it, is a standard crashpad .
I wrote the test using the standard class from chromium EmbeddedTestServer ( link )
In fact, the whole test is a call to the EmbeddedTestServer::InitializeAndListen method + code that returns html (there is a standard stuffing from socket+bind+listen+accept+recv+send inside) .

Next, I opened the browser, made sure that the server is visible at 127.0.0.1:8080
I launched the crash reporter and .... it does not see the server.
OK. I took node js, wrote a primitive http server on it ( like this ). Launched, and made sure that the server is visible both from the browser and from the crash reporter.

And now I'm tormented by the question: how the hell? After all, in fact, in both cases there is a certain listening socket, which (after connecting) starts to give html.
But when this socket is wrapped in chromium code, and running in a separate process, it is "visible" only from the browser. And when the socket lives inside node js, it is suddenly visible from the crash reporter too.
Why??

I have only one guess: the crash reporter uses winhttp to work, and the normal browser, apparently, winsock. But when using a local server, this probably doesn't matter. Again, node js works great in both cases.
What other differences can these two "servers" have?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question