Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Periodic Background Sync
Search
Jxck
April 17, 2020
Technology
0
510
Periodic Background Sync
LT about periodic background sync at #remo_study
Jxck
April 17, 2020
Tweet
Share
More Decks by Jxck
See All by Jxck
IE Graduation (IE の功績を讃える)
jxck
22
15k
IE Graduation Certificate
jxck
6
5.9k
RFC 9111: HTTP Caching
jxck
0
600
tc39_study_2
jxck
1
4.2k
IETF における ABNF とプロトコルパーサの話 / ABNF for Protocol Parser @ IETF
jxck
2
980
Web Components 元年 v3 / Web Components first year v3
jxck
1
940
Podcast over PWA
jxck
0
220
Yearly Web 2019
jxck
0
140
webbundle_study
jxck
2
570
Other Decks in Technology
See All in Technology
新R25、乃木坂46 Mobileなどのファンビジネスを支えるマルチテナンシーなプラットフォームの全体像 / cam-multi-cloud
cyberagentdevelopers
PRO
1
110
新卒1年目が挑む!生成AI × マルチエージェントで実現する次世代オンボーディング / operation-ai-onboarding
cyberagentdevelopers
PRO
0
100
Mobbing Practices
kawaguti
PRO
3
340
Trusted Types API と Vue.js
lycorptech_jp
PRO
1
300
Comparing Apache Flink and Spark for Modern Stream Data Processing
sharonx
0
180
サーバーサイドのデータプレーンプログラミング 〜 NVIDIA Blue Field / DOCA 〜
ebiken
PRO
1
230
クライアントサイドでよく使われる Debounce処理 をサーバサイドで3回実装した話
yoshiori
1
130
独自ツール開発でスタジオ撮影をDX!「VLS(Virtual LED Studio)」 / dx-studio-vls
cyberagentdevelopers
PRO
0
110
わたしとトラックポイント / TrackPoint tips
masahirokawahara
1
200
なんで、私がAWS Heroに!? 〜社外の広い世界に一歩踏み出そう〜
minorun365
PRO
1
540
Jamstack でリニューアルするグリーグループのメディア
gree_tech
PRO
2
220
現地でMeet Upをやる場合の注意点〜反省点を添えて〜
shotashiratori
0
160
Featured
See All Featured
Gamification - CAS2011
davidbonilla
80
5k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
27
4.1k
Why You Should Never Use an ORM
jnunemaker
PRO
53
9k
Intergalactic Javascript Robots from Outer Space
tanoku
268
27k
What's in a price? How to price your products and services
michaelherold
243
11k
The World Runs on Bad Software
bkeepers
PRO
65
11k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
41
9.2k
GraphQLの誤解/rethinking-graphql
sonatard
66
9.9k
Code Reviewing Like a Champion
maltzj
519
39k
Measuring & Analyzing Core Web Vitals
bluesmoon
0
29
KATA
mclloyd
29
13k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
131
33k
Transcript
Periodic Background Sync Periodic Background Sync
None
Background Sync self.on('sync', (e) => { // retry failed request
while // offline in background })
Periodic Background Sync self.on('periodic-sync', (e) => { // periodically refresh
contents // up to date in background. })
Use Case - Podcast Feed Update
// register PBS const name = 'periodic-background-sync' const status =
await navigator.permissions.query({name}) if (status.state === 'granted') { await registration.periodicSync.register('refresh', { minInterval: 12 * 60 * 60 * 1000 // 12h }) }
Security Consideration
#4: 156.74.xxx.xxx #1: 14.102.xxx.xxx #2: 81.177.xxx.xxx #3: 24.152.xxx.xxx Background Sync
Tracking also • crypto mining • bot net
Known Network
Permission In Chrome
Permission Model Permission Dialog ? User Gesture ? Feature Policy
? Add to Home Screen !!
Native App Permission -> Install Web App Permission -> Install
Restriction In Chrome
• Periodic depends on site-engagement. • Only fire under known
network.
Site Engagement
Periodic Background Sync enables... • Installed App via A2HS •
Enough Site-Engagement • Connected to Known Network • Android Chrome only
Work in progress...
None