Multicast Sockets

Practical Guide for Programmers


  • David Makofske, Akamai Technologies, Fort Lee, NJ
  • Kevin Almeroth, University of California at Santa Barbara

Multicast Sockets: Practical Guide for Programmers is a hands-on, application-centric approach to multicasting (as opposed to a network-centric one) that is filled with examples, ideas, and experimentation. Each example builds on the last to introduce multicast concepts, frameworks, and APIs in an engaging manner that does not burden the reader with lots of theory and jargon. The book is an introduction to multicasting but assumes that the reader has a background in network programming and is proficient in C or Java. After reading the book, you will have a firm grasp on how to write a multicast program.

View full description


software engineers, developers, and application programmers building applications for multicast-enabled networks, and advanced networking students


Book information

  • Published: November 2002
  • ISBN: 978-1-55860-846-7


This is a terrific hands-on guide to programming multicast Internet applications. Gathering together all of the needed information, techniques, and illustrative examples in one place, it is the best source for material on multicast socket programming. -James F. Kurose, Professor of Computer Science, University of Massachusetts, Amherst Makofske and Almeroth have provided just the jump-start that most programmers will need to get started with multicast. Using the examples provided, any competent coder will be able to safely send and receive multicast packets in short order. Think of this as the crystal radio kit of multicast applications—and I mean that in the best possible sense. —Lucy Lynch, Computing Center, University of Oregon Until now, programming multicast applications has been an arcane pursuit, accessible to a select few. This book changes all that. It is very timely, with an introduction to programming multicast in .NET, in addition to Java and C. It is also very comprehensive, with a nice discussion of the history of multicast development. —Ramesh Govindan, University of Southern California

Table of Contents

1 Introduction 1.1 Multicast Defined1.2 Unicast vs. Multicast vs. Broadcast 1.3 The Multicast Tradeoff: Power/Flexibility vs. Complexity 1.4 An Overview of Multicast Protocols 1.5 Organization of this Book 2 Multicasting with C Sockets 2.1 UDP Sockets 2.2 Sending Multicast Packets in C 2.3 Receiving Multicast Packets in C 2.4 A Sample Run of Sender and Receiver(s) 2.5 C and Source Specific Multicast 2.6 WinSock Modifications 3 Multicasting with Java 3.1 The Java MulticastSocket API 3.2 A Java Multicast Sender 3.3 Receiving Multicast Packets in Java 3.4 A Sample Run 4 Multicasting with .NET 4.1 The .NET Sockets Class 4.2 Sending Multicast Packets in C# 4.3 Receiving Multicast Packets in C# 4.4 A Sample Run: C# Multicast Sender and Receiver 4.5 C# and Source Specific Multicast 4.6 The C# UdpClient Class 5 Source Specific Multicast 5.1 Source Specific Multicast Defined 5.2 Advantages of SSM 5.3 Host Support for SSM 5.4 SSM Additions to the APIs 6 Multicast Addressing and Scoping 6.1 Scoping 6.2 Multicast Address Space 6.3 Selecting a Multicast Address 6.4 Java Multicast Address Scope Methods 7 Multicast Reachability and Scalability 7.1 Multicast Reachability 7.2 Multicast Ping 7.3 Multicast Scalability 7.4 MPing with Receiver-based Congestion Control 8 Application Layer Multicast and Reflectors 8.1 Introduction 8.2 A Multicast Reflector in Java 9 Summarizing Lessons Learned A Multicast History and Protocols B Summary of Multicast API by Language