Recall From SHDH 17
Jeff Lindsay’s
“Web hooks”
lightning talk
• RSS relies on polling.
• Polling is lame.
• Syndication and
(re)publishing, not
triggering
Recall From SHDH 17
Jeff Lindsay’s
“Web hooks”
NO
lightning talk
• Often n consumers.
• Not 1000n.
• Polling is still lame.
(for some things) • Are we there yet?
• Are we there yet?
• Are we there yet?
Recall From SHDH 17
Jeff Lindsay’s
“Web hooks”
lightning talk
• Event-driven.
• Lightweight.
• POST to a URL.
Recall From SHDH 17
Jeff Lindsay’s
“Web hooks”
OLD LOGO
lightning talk
• Event-driven.
• Lightweight.
• POST to a URL.
Web hooks in practice
//something ...
hook_trigger(‘viewpage’);
//more stuff..
async
async
while(1) {
while($queued = $q->get(‘async-queue’)) {
post_to_url($queued[‘url’],$queued[‘postargs’]);
}
}
Web hooks in practice
Example hooked events
• login/logout
• edit a page
• revert a page
• delete a page
• comment on a page
• tag/untag pages
• join/unjoin wiki
• return_after_absence
• view_for_first_time