How does localhost 127.0.0.1 work?
I'm wondering how does
localhost:8080 works? Who is sitting behind the scenes and handling my request's? How all request's are handling simultaneously and who does this job?
Super User is a question and answer site for computer enthusiasts and power users. It only takes a minute to sign up.Sign up to join this community
Any program running on your computer can answer a network request on a port that isn't already in use. "Localhost" is a "Well known" address meaning the local machine, via IP address 127.0.0.1
Now, which program running on your computer is listening to port 8080? I don't know. Determining that depends on your hardware and software.
http://en.wikipedia.org/wiki/List_of_TCP_and_UDP_port_numbers says that 8080 is often used for proxy and caching programs as well as Apache, which is web server software you can choose to run. But it could be anything.
Your operating system's hosts file contains this entry:
127.0.0.1 belongs to the loopback network interface, which is available whether you have an actual network connection or not. You can therefore run a web server and tell it to listen for connections on port 8080 to the 127.0.0.1 address, which you can connect to even when disconnected from the Internet.
:8080 part of the URL tells your web browser to connect to port 8080 rather than the usual port 80 used for HTTP connections. Developers often run local web servers on port 8080 because Unix-like systems (Mac OS X and Linux) only allow the user "root", the "superuser", to listen for connections to port numbers below 1024. (8080 is greater than 1023, allowing the developer to run the server from his own user account rather than as a system service.)
In computer networking, localhost (meaning this computer) is the standard hostname given to the address of the loopback network interface