Skip to content

Instantly share code, notes, and snippets.

View kudrin's full-sized avatar
💭
:rage1: :rage2: :rage3: :rage4:

Alexander Kudrin kudrin

💭
:rage1: :rage2: :rage3: :rage4:
View GitHub Profile
This is ApacheBench, Version 2.3 <$Revision: 1706008 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/
Benchmarking localhost (be patient)
Server Software: thin
Server Hostname: localhost
Server Port: 3002

Massive file upload using JQueryUpload + Nginx + Rails + Sidekiq

The goal: Upload several files (virtually big files) to a Rails application without compromising the user experience.

Architecture

jQuery File Upload + Nginx + Rails (Carrierwave) + Sidekiq

  1. jQuery File Upload (http://blueimp.github.io/jQuery-File-Upload/)
@kudrin
kudrin / gist:6712500
Created September 26, 2013 10:39
Thinking sphinx log
[Thu Sep 26 13:15:40.876 2013] [12517] rotating index: all indexes done
[Thu Sep 26 13:15:45.980 2013] [12517] caught SIGHUP (seamless=1, in queue=1)
[Thu Sep 26 13:15:45.983 2013] [12517] rotating index 'result_delta': started
[Thu Sep 26 13:15:45.984 2013] [12517] rotating index 'result_delta': success
[Thu Sep 26 13:15:45.984 2013] [12517] rotating index: all indexes done
[Thu Sep 26 13:15:46.122 2013] [12517] caught SIGHUP (seamless=1, in queue=1)
[Thu Sep 26 13:15:46.134 2013] [12517] rotating index 'task_delta': started
[Thu Sep 26 13:15:46.135 2013] [12517] rotating index 'task_delta': success
[Thu Sep 26 13:15:46.135 2013] [12517] rotating index: all indexes done
[Thu Sep 26 13:16:02.301 2013] [12517] caught SIGHUP (seamless=1, in queue=1)
@kudrin
kudrin / Tseeror2
Created September 19, 2013 08:44
Thinking sphinx error
mysql2 (0.3.13) lib/mysql2/client.rb:58:in `connect'
mysql2 (0.3.13) lib/mysql2/client.rb:58:in `initialize'
/var/www/millionagents/shared/bundle/ruby/1.9.1/bundler/gems/thinking-sphinx-9b1f0f027307/lib/thinking_sphinx/connection.rb:60:in `new'
/var/www/millionagents/shared/bundle/ruby/1.9.1/bundler/gems/thinking-sphinx-9b1f0f027307/lib/thinking_sphinx/connection.rb:60:in `initialize'
/var/www/millionagents/shared/bundle/ruby/1.9.1/bundler/gems/thinking-sphinx-9b1f0f027307/lib/thinking_sphinx/connection.rb:15:in `new'
/var/www/millionagents/shared/bundle/ruby/1.9.1/bundler/gems/thinking-sphinx-9b1f0f027307/lib/thinking_sphinx/connection.rb:15:in `new'
/var/www/millionagents/shared/bundle/ruby/1.9.1/bundler/gems/thinking-sphinx-9b1f0f027307/lib/thinking_sphinx/connection.rb:27:in `block in pool'
innertube (1.1.0) lib/innertube.rb:131:in `call'
innertube (1.1.0) lib/innertube.rb:131:in `block in take'
<internal:prelude>:10:in `synchronize'
@kudrin
kudrin / Tserror
Created September 19, 2013 08:39
Thinking sphinx error
mysql2 (0.3.13) lib/mysql2/client.rb:58:in `connect'
mysql2 (0.3.13) lib/mysql2/client.rb:58:in `initialize'
/var/www/millionagents/shared/bundle/ruby/1.9.1/bundler/gems/thinking-sphinx-9b1f0f027307/lib/thinking_sphinx/connection.rb:60:in `new'
/var/www/millionagents/shared/bundle/ruby/1.9.1/bundler/gems/thinking-sphinx-9b1f0f027307/lib/thinking_sphinx/connection.rb:60:in `initialize'
/var/www/millionagents/shared/bundle/ruby/1.9.1/bundler/gems/thinking-sphinx-9b1f0f027307/lib/thinking_sphinx/connection.rb:15:in `new'
/var/www/millionagents/shared/bundle/ruby/1.9.1/bundler/gems/thinking-sphinx-9b1f0f027307/lib/thinking_sphinx/connection.rb:15:in `new'
/var/www/millionagents/shared/bundle/ruby/1.9.1/bundler/gems/thinking-sphinx-9b1f0f027307/lib/thinking_sphinx/connection.rb:27:in `block in pool'
innertube (1.1.0) lib/innertube.rb:131:in `call'
innertube (1.1.0) lib/innertube.rb:131:in `block in take'
<internal:prelude>:10:in `synchronize'