HTTP upload server in Ruby

390 Views Asked by At

I'm thinking to build an HTTP upload server in Ruby for my project. So far, I'm looking at setting up a Rack server to run with "Rainbow!" or a sinatra server with Rack middleware. The server is required to support HTTP uploads with multipart and chunking. Is this a good choice?

I'd love to see some examples how to set up a simple HTTP upload server but I couldn't find anywhere on the 'net.

1

There are 1 best solutions below

0
On

Since a file upload can take a while, an important point of uploading files in Ruby are blocking processes while a file is uploaded. You might want to look into projects that are based on EventMachine and/or Goliath to achieve non-blocking processing of HTTP requests. Some ideas here: