Chapter 11: Network Programming
In this chapter, we will describe and discuss the most popular network protocols – User Datagram Protocol (UDP), Transmission Control Protocol (TCP), HyperText Transfer Protocol (HTTP), and WebSocket – and their support from the Java Class Library (JCL). We will demonstrate how to use these protocols and how to implement client-server communication in Java code. We will also review Uniform Resource Locator (URL)-based communication and the latest Java HTTP Client API. After studying this chapter, you will be able to create server and client applications that communicate using the UDP, TCP, and HTTP protocols as well as WebSocket.
The following topics will be covered in this chapter:
- Network protocols
- UDP-based ...
Get Learn Java 17 Programming - Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.