A Java-based Distributed IP Phone System
by
Jia YU (ID:13156578)
Minor Thesis
Submitted in partial fulfillment of the requirements for the degree of
Master of Network Computing
Supervisor
Dr. Jan Newmarch
School of Network Computing
Monash University
July, 2002
i
Declaration
I declare that this minor thesis is my own work and has not been
submitted in any form for another degree or diploma at any university
or other institute of tertiary education. Information derived from the
published and unpublished work of others has been acknowledged in
the text and a list of references is given.
Jia YU
July 22, 2002
ii
Acknowledgements
I would like to thank Sun Microsystems, Melbourne for providing facilities and professional
directions for this project, especially Michael Geisler (System Engineer).
I also would like to thank my supervisor Dr. Jan Newmarch, Rob Gray, my family and other
people who have given me support during this semester.
I wish to thank members of Madison project and Siptrex project. Without their contributions,
I could not have finished this project in such limited time.
iii
Abstract
The development of conventional telephony systems is far behind the development of today’s
Internet. Centralized architectures with dumb terminals make exchange software and
hardware very complex, but provide very limited functions. It is very hard for one company
to choose products from more than one vendor, due to the closed system architecture.
VoIP can promise cheaper communications and more services. Since IP networks are
ubiquitous and voice can be transmitted over IP, it is not necessary to develop another
network to transmit voice only. It is also easy for VoIP to integrate voice communication
with other IP applications; a call can be made by just one mouse click. However, many
current VoIP solutions have the same problems as traditional telephony systems. Its
centralized architecture makes it hard for enterprise to deploy special services for their
business need.
This project aims to set up a distributed IP phone system using Java technology. Session
Initiation Protocol (SIP) is used as the phone signalling protocol. It also investigates several
telecommunication-related Java standards, especially JAIN API and Java Trouble Ticket API.
IP phones in this project are intelligent; in other words, they can run programs and consume
other services. Therefore, service discovery is very important in IP phone systems. Jini is a
good middleware technology for service discovery. Finding solutions for putting IP phone
devices and J2EE services on the Jini federation is another part of this project.
iv
C o n t e n t s
1.Introduction ..........................................................................................1
1.1 Advantages of Voice over IP?........................................................................................................................1
1.2 Why distributed architecture? ........................................................................................................................1
1.3 Contributions..................................................................................................................................................2
1.4 Organization...................................................................................................................................................3
2. Enabling technologies for IP phone systems .............................................4
2.1 Voice Coders..................................................................................................................................................4
2.2 Transport and protocols..................................................................................................................................5
2.3 Signalling .......................................................................................................................................................6
2.3.1 Overview of signaling protocols for IP phone applications....................................................................6
2.3.2 SIP ...........................................................................................................................................................8
2.4 IP phone devices...........................................................................................................................................11
2.5 Java in IP phone devices ..............................................................................................................................12
2.5.1 Drawback of Java in embedded IP phone devices ................................................................................12
2.5.2 PersonalJava solution for IP phone devices ..........................................................................................13
2.6 Java APIs for audio applications..................................................................................................................14
2.7 JAIN .............................................................................................................................................................15
2.7.1 Overview of JAIN .................................................................................................................................15
2.7.2 SIP in JAIN ...........................................................................................................................................17
2.7.3 JAIN SIP API........................................................................................................................................17
2.8 Jini technology .............................................................................................................................................18
2.8.1 Overview of Jini....................................................................................................................................18
2.8.2 Problems with current Jini implementation for small devices ..............................................................20
2.8.3 Jini surrogate architecture .....................................................................................................................21
2.9 J2EE .............................................................................................................................................................23
2.10 OSS/J..........................................................................................................................................................23
3. Distributed IP phone call service...........................................................26
3.1 Overview ......................................................................................................................................................26
3.2 System Analysis and Design........................................................................................................................26
3.2.1 Architecture...........................................................................................................................................26
3.2.2 Registration ...........................................................................................................................................28
3.2.3 Phone call processing............................................................................................................................29
3.2.4 Personal mobility...................................................................................................................................32
3.2.5 Dialing principle in the system..............................................................................................................33
3.3 Deployment detail ........................................................................................................................................33
3.4 JAIN SIP API implementation discussion ...................................................................................................34
3.5 Further work.................................................................................................................................................35
3.5.1 Character supporting dialing application ..............................................................................................35
3.5.2 Multi-phone supporting.........................................................................................................................36
3.5.3 Multi-call forwarding ............................................................................................................................36
3.5.4 Security issue.........................................................................................................................................37
3.6 Conclusion....................................................................................................................................................38
4. Jini based phone service.......................................................................39
4.1 Overview ......................................................................................................................................................39
4.2 Analysis........................................................................................................................................................39
4.2.1 Architecture...........................................................................................................................................39
4.2.2 Life time of surrogates of IP phones .....................................................................................................41
4.2.3 Announcement packet and registration message ..................................................................................43
4.3 Design...........................................................................................................................................................45
4.3.1 Package diagram of Jini solution for PersonalJava IP phones..............................................................45
4.3.2 Class diagram of the surrogate handler package...................................................................................46
4.3.3 Sequence diagram of surrogate registration ..........................................................................................47
4.3.4 Sequence diagram of surrogate monitoring ..........................................................................................50
4.3.5 Class diagram of the IP phone surrogate package.................................................................................51
4.3.6 Sequence diagram of liveness of processing for a phone surrogate......................................................51
4.4 Deployment ..................................................................................................................................................54