In the web world, the web browser makes a new request for each static file it needs to extract, therefore; stylesheet, javascript file, inline image - all initiate a new server request. Although my knowledge of the Internet is pretty good, basic technologies such as websockets are somewhat new to me in how they work and what they are capable of.
My question is pretty theoretical, but I wonder if it is possible now or will static files be possible through websocket? Given that web ports are a permanent connection to a client (web browser) on a server, it makes sense that web ports can be used to serve some, if not all, static content, as this will be just one connection, not many.
To clarify a bit.
I understand that my wording on connections was incorrect, as indicated by Greg below. But from what I understand, the reason that CDNs were created and are still in use today is to solve the problem with browsers and / or servers having a hard limit on the number of simultaneous downloads, as soon as you click this restriction, your requests are then queued, adding to page load time. I know that they were also created to provide cookie-free requests. So really my question should be this: "Can websockets be used instead of CDNs?"
BrowserScope has some useful indicators, it seems that the request limit is about 6 per host name for most modern browsers and even IE8. But, as I said, sometimes people have more than 6 resources, does this mean that they are in line and slow down page load time, when websites can potentially reduce this to one?
source
share