0
Reboot
7y

Guys, how the code we write are implemented in the server ?

How it is accessed by thousands or millions of people's ?

I know these are basic questions. But, if anyone answers it will be helpful.

Comments
  • 0
    Code... as in...? What? Websites?
  • 0
    @ScribeOfGoD I am not asking about HTML and CSS those things.

    I want to know about the back end process and how it's logic is accessed by millions of people at same time ?
  • 0
    @vasanth with various amount of different code
  • 0
  • 3
    Vasanth: essentially, a client makes a request (GET/POST/etc), the request is interpreted and redirected by some library such as flask or the http server, the backend code (python/C/whatever) gets called as soon as this happens, it runs and does its thing, it all goes back up the chain and returns a result in the form of a http code/headers and body.

    This process can be queued as requests come in and dispatched by worker threads.
  • 0
    @jespersh

    Eventhough we wrote the logic only once. It will be implemented on every server and each server can handle multiple requests by using mulithreading.... right ?
  • 0
  • 0
    @xsacha

    Where our code(python/c/java) is stored and how different threads uses it? Does each server have to store the code right ?

    I'm sry if it is very basic. I wants to know and it is really bothering me !!!
  • 0
    @xsacha

    I'm understanding a little.
    Thanks :)
  • 1
    @vasanth your back-end code will be on every server, most likely as a library (like .so file). Make sure it's thread-safe so it doesn't crash when multiple users access the same data of course.
Add Comment