Professional Documents
Culture Documents
Streaming
P2P Protocol
Gunnar Kreitz
Background
Streaming
P2P Protocol
What is Spotify?
Legal
Background
Streaming
P2P Protocol
Business Idea
Gunnar Kreitz
Background
Streaming
P2P Protocol
Business Idea
Gunnar Kreitz
Background
Streaming
P2P Protocol
Gunnar Kreitz
Background
Streaming
P2P Protocol
Development Environment
Hack days
Gunnar Kreitz
Background
Streaming
P2P Protocol
Available
Fast
Scalable
Secure
Gunnar Kreitz
Background
Streaming
P2P Protocol
Gunnar Kreitz
Background
Streaming
P2P Protocol
Background
Streaming
P2P Protocol
Client Software
Gunnar Kreitz
Background
Streaming
P2P Protocol
Gunnar Kreitz
Background
Streaming
P2P Protocol
Everything is a link
spotify:track:6JEK0CvvjDjjMUBFoXShNZ#0:44
spotify:user:gkreitz:playlist:
4W5L19AvhsGC3U9xm6lQ9Q
spotify:search:never+gonna+give+you+up
http://open.spotify.com/track/
6JEK0CvvjDjjMUBFoXShNZ#0:44
Gunnar Kreitz
Background
Streaming
P2P Protocol
Everything is a link
spotify:track:6JEK0CvvjDjjMUBFoXShNZ#0:44
spotify:user:gkreitz:playlist:
4W5L19AvhsGC3U9xm6lQ9Q
spotify:search:never+gonna+give+you+up
http://open.spotify.com/track/
6JEK0CvvjDjjMUBFoXShNZ#0:44
Gunnar Kreitz
Background
Streaming
P2P Protocol
Background
Streaming
P2P Protocol
Metadata API
http://ws.spotify.com/lookup/1/?uri=spotify:track:
6JEK0CvvjDjjMUBFoXShNZ
http://ws.spotify.com/search/1/artist?q=foo
Gunnar Kreitz
Background
Streaming
P2P Protocol
Proprietary protocol
96320 kbps audio streams (most are Ogg Vorbis q5, 160 kbps)
Peer-assisted streaming
Background
Streaming
P2P Protocol
Spotify Protocol
Gunnar Kreitz
Background
Streaming
P2P Protocol
Caches
Gunnar Kreitz
Background
Streaming
P2P Protocol
Streaming a Track
Gunnar Kreitz
Background
Streaming
P2P Protocol
A TCP sender can never have more than cwnd un-ack:ed bytes
outstanding
Gunnar Kreitz
Background
Streaming
P2P Protocol
A TCP sender can never have more than cwnd un-ack:ed bytes
outstanding
Gunnar Kreitz
Background
Streaming
P2P Protocol
Gunnar Kreitz
Background
Streaming
P2P Protocol
I
I
Heuristics
Background
Streaming
P2P Protocol
Background
Streaming
P2P Protocol
Background
Streaming
P2P Protocol
P2P Goals
Easier to scale
Less servers
Lass bandwidth
Better uptime
Fun!
Gunnar Kreitz
Background
Streaming
P2P Protocol
Music
Movies
Many plays/session
Large catalog
Active users
Main problem: peer discovery
I
Gunnar Kreitz
Background
Streaming
P2P Protocol
Music
Movies
Many plays/session
Large catalog
Active users
Main problem: peer discovery
I
Gunnar Kreitz
Background
Streaming
P2P Protocol
P2P Structure
No overlay routing
Gunnar Kreitz
Background
Streaming
P2P Protocol
P2P Structure
Gunnar Kreitz
Background
Streaming
P2P Protocol
One (well, three) P2P overlay for all tracks (not per-torrent)
Gunnar Kreitz
Background
Streaming
P2P Protocol
Finding Peers
Gunnar Kreitz
Background
Streaming
P2P Protocol
Downloading in P2P
When doing so, estimate what point P2P will catch up from
Gunnar Kreitz
Background
Streaming
P2P Protocol
I
I
Gunnar Kreitz
Background
Streaming
P2P Protocol
Gunnar Kreitz
Background
Streaming
P2P Protocol
Gunnar Kreitz
Background
Streaming
P2P Protocol
Avoiding hijacking
Gunnar Kreitz
Background
Streaming
P2P Protocol
Gunnar Kreitz
Background
Streaming
P2P Protocol
High-level overview
Gunnar Kreitz
Background
Streaming
P2P Protocol
Proprietary
HTTP
Client
Proprietary
AP
Playlist
Search
HTTP
HTTP
Storage
User
Gunnar Kreitz
Background
Streaming
P2P Protocol
Gunnar Kreitz
Background
Streaming
P2P Protocol
I
I
Gunnar Kreitz
Background
Streaming
P2P Protocol
Lookup, version 1
Scaling issues
Gunnar Kreitz
Background
Streaming
P2P Protocol
Lookup, version 2
Gunnar Kreitz
Background
Streaming
P2P Protocol
Storage
Gunnar Kreitz
Background
Streaming
P2P Protocol
Playlist
Gunnar Kreitz
Background
Streaming
P2P Protocol
Evaluation
Gunnar Kreitz
Background
Streaming
P2P Protocol
Data Sources
RRDTOOL / TOBI OETIKER
60
Weekend
Night
Weekday
Morning
50
40
30
20
10
0
Mon
Tue
Wed
Thu
Fri
Cur:
10.86
33.90
55.24
Server
P2P
Cache
Gunnar Kreitz
Sat
Sun
Min:
6.76
23.78
48.47
Mon
Avg:
9.62
33.86
56.53
Background
Streaming
P2P Protocol
Data Sources
Gunnar Kreitz
Background
Streaming
P2P Protocol
Gunnar Kreitz
Background
Streaming
P2P Protocol
Finding Peers
Fraction of searches
75.1%
9.0%
7.0%
8.9%
Gunnar Kreitz
Background
Streaming
P2P Protocol
Protocol Overhead
Type
Music Data, Used
Music Data, Unused
Search Overhead
Other Overhead
Fraction
94.80%
2.38%
2.33%
0.48%
Gunnar Kreitz
Background
Streaming
P2P Protocol
More measurements
How many IPs does each user connect form over a week?
Background
Streaming
P2P Protocol
Gunnar Kreitz