learning erlang and developing a sip server stack with 30k potential users

9

Click here to load reader

Upload: l-xf

Post on 26-May-2015

2.995 views

Category:

Technology


1 download

TRANSCRIPT

Page 1: Learning Erlang And Developing A Sip Server Stack With 30k Potential Users

Learning Erlang and developing a SIP server/stack with 30k potential users

Fredrik Thulin <sip:[email protected]>Enheten för IT och media

Stockholms universitet

EUC2004

Page 2: Learning Erlang And Developing A Sip Server Stack With 30k Potential Users

Stockholm university telephony in 1997 :

● Ericsson MD110● 5000 subscribers

2000 :● Ericsson MD110 – 4200 subscribers● Cisco CallManager – 800 subscribers

● Early VoIP adopters, but still no open standard

Page 3: Learning Erlang And Developing A Sip Server Stack With 30k Potential Users

SIP

● Session Initiation Protocol● IETF proposed standard (RFC3261, 2, 3, 4 and 5)● Does not care about audio/video/whatever● Instant messaging and presence● Parsing is hard, even though (?) it's plain text● Transactions are complex● Few open source implementations as to date

Page 4: Learning Erlang And Developing A Sip Server Stack With 30k Potential Users

Personal Erlang experience

● No prior knowledge about functional programming

● Hard time understanding some syntax (strings are lists, [H | T] = “string”)

● Assign once● Really like cheap processes and the IPC

Page 5: Learning Erlang And Developing A Sip Server Stack With 30k Potential Users

Implementation

● Magnus Ahltorp, KTH made a couple of implementations in Perl, Python, C, ...

● Erlang implementation was the most viable one

● First Yxa snapshot released 2003­10­07● OTP supervisor model● 15000 lines of code, 5000 lines of comments

Page 6: Learning Erlang And Developing A Sip Server Stack With 30k Potential Users

OTP supervisor model

sipsocket

sipsocket_udp tcp_dispatcher

tcp_listener

directorylogger

sipserver_sup

transaction_layer

Page 7: Learning Erlang And Developing A Sip Server Stack With 30k Potential Users

Plans

● Build distributed SIP servers– for routing

– for students (free VoIP/SIP­service, no PSTN)

– for basic call service? Evaluating.

● Distributed policy control (perimeter defense ­ rate limiting etc.)

● External event logging with call context● RFC compliant stack, easy to write applications

Page 8: Learning Erlang And Developing A Sip Server Stack With 30k Potential Users

Perimeter defense

Internet

– Rate limiting number of ongoing calls per host, class C network, domain, SSL certificate etc.

Servers running Yxa incomingproxy

Page 9: Learning Erlang And Developing A Sip Server Stack With 30k Potential Users

Project

● http://www.stacken.kth.se/projekt/yxa/