Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Sidekiq under the hood
Search
Anton Davydov
September 26, 2015
Programming
470
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Sidekiq under the hood
Anton Davydov
September 26, 2015
Transcript
40 slides
Hello!
github: davydovanton twitter: anton_davydov Anton Davydov
RCNTEC developer sidekiq commiter ruby doc / rails / crystal
OSS one love <3
@rubyunderhood curator https://twitter.com/rubyunderhood
@moscowrb http://moscow-rb.org
You Beer
You Beer Me
I (we) <3 sidekiq!
Simple, efficient background processing for Ruby.
Sidekiq server New thread
I (we) <3 actors!
Manager actor
Fetcher actors Manager actor
Redis Fetcher actors Manager actor
Redis Fetcher actors Processor actors Manager actor
Redis Fetcher actors Processor actors Manager actor Workers
MyWorker.perform_async
irb > MyWorker.perform_async Redis queue Serialization prams
Processor actors Fetcher actors Redis Manager actor Workers
Processor actors Manager actor Workers Fetcher actors Redis
Processor actors Manager actor Workers Fetcher actors Redis
Workers Processor actors Manager actor Fetcher actors Redis
LongWorker Redis
Redis Serialization prams LongWorker After 8 seconds
middleware
Sidekiq.configure_server do |config| config.server_middleware do |chain| chain.add YourMiddleware, options end
end
def call(worker, msg, queue) # code before call you worker
yield rescue => e # run if your worker is failed raise e ensure # run in your worker passed or failed end
def call(worker, msg, queue) # code before call you worker
yield rescue => e # run if your worker is failed raise e ensure # run in your worker passed or failed end
def call(worker, msg, queue) # code before call you worker
yield rescue => e # run if your worker is failed raise e ensure # run in your worker passed or failed end
def call(worker, msg, queue) # code before call you worker
yield rescue => e # run if your worker is failed raise e ensure # run in your worker passed or failed end
Sidekiq-statistic github.com/davydovanton/sidekiq-statistic
Improved display of statistics for your sidekiq workers and jobs.
None
None
None
None
Worker name Last job status Runtime Start time
Jobs per day charts for each worker Last job status
for each worker Passed and failed jobs count Average job time Max and min jobs time Total jobs time Last job time
I <3 feedback!
Anton Davydov github.com/davydovanton twitter.com/anton_davydov Thank you!
More Decks by Anton Davydov
See All by Anton Davydov
How to make a technical decision
davydovanton
0
160
МГТУ
davydovanton
0
130
Events. Events. Events! - krk.rb
davydovanton
0
170
Events. Events. Events!
davydovanton
0
880
Event Sourcing RubySPBConf 2k18
davydovanton
1
230
Architecture of hanami applications
davydovanton
1
7.8k
Hanami Architecture
davydovanton
2
350
viewing ruby blossom kaigi2017
davydovanton
0
790
viewing ruby blossom rdrc2017
davydovanton
2
260
Other Decks in Programming
See All in Programming
RaspberryPi 5で軽くはじめるk3sとtailscaleを用いたホームサーバー構築 (1)
nasum
0
410
Debian JP Projectのサーバー構成
uwabami
1
150
Rails初心者がパスキーを実装してみて大変だったこと
ktombow
0
220
AI時代のFlutter品質設計 — アプリ品質を守るQuality Layers
omatty198
0
390
まずはコードより業務と向き合う:テーブル解体のためにPdMを呼んだ話
sakawe_ee
0
260
TanStack Vue Query と Pinia Colada から学ぶ非同期状態の型設計
aoshi
0
690
Distance field of Julia set
kinakomoti321
0
330
Spec-driven Development with AI
simas
PRO
0
2.3k
protojson における文字化けの扱い
kazuki1023
0
450
コード生成時代のAPI定義を支えるRequest Spec移行
pvcresin
0
290
小さなアプリを作って公開するまで
onozaty
0
210
はじめてのPLATEAU
nokonoko1203
1
660
Featured
See All Featured
The innovator’s Mindset - Leading Through an Era of Exponential Change - McGill University 2025
jdejongh
PRO
1
400
Embracing the Ebb and Flow
colly
88
5.2k
Digital Ethics as a Driver of Design Innovation
axbom
PRO
2
540
Claude Code のすすめ
schroneko
67
230k
Self-Hosted WebAssembly Runtime for Runtime-Neutral Checkpoint/Restore in Edge–Cloud Continuum
chikuwait
0
960
Future Trends and Review - Lecture 12 - Web Technologies (1019888BNR)
signer
PRO
0
3.8k
Optimising Largest Contentful Paint
csswizardry
37
4k
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
470
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
230
23k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
47
8.4k
Paper Plane (Part 1)
katiecoart
PRO
3
12k
The Illustrated Guide to Node.js - THAT Conference 2024
reverentgeek
1
610