Rack middleware for handling large file uploads