title: Creating Server Processing Queue
body: <p>I am not even quite sure how to ask this question as it is sort of an overall conceptual issue but I figured I'd give it a try.</p>
  
  <p>I am trying to create a process conceptually similar to many of the video hosting websites out there like Vimeo.  Using Vimeo as an example, the user uploads a video to the main server, the video is added to a processing queue, and the user is free to go do other things while the video is processing.  Sometime later, the user receives an email saying that the processing is complete and the video can now be accessed and the user can do whatever they want with it.  </p>
  
  <p>My question is this, how does a system like this work?  My experience is primarily with PHP where all the processing is tied directly to the code in that page (or via includes).  How do you deal with things like this processing while the user navigates away from the page?</p>
  
  <p>This is my guess...  Please correct me.  The page submitted by the user adds their file to the processing software queue via some sort of API Hook.  The processor which is probably written in some other language like C or Java or whatever, does its thing and then when it is finished, it fires a call to some PHP page that then sends the user an email and does whatever needs to be done with the video.  </p>
  
  <p>I guess I am just trying to understand how the "black boxes" of some of the big websites out there work, at least conceptually.  Can anyone help me out here?  Sorry it is such a big, vague question.</p>