Class Lectures and Reading Assignments
CS 33600
Network Programming
Spring, 2025
This page documents what we do in class. It contains Java programs that we will discuss in class, reading assignments, simple homework exercises that you can work on for practice and exam preparation (not for credit), and links to other sources of information. It is a good idea for you to "play" with the example Java programs; compile them, run them, make simple changes to them and compile and run them again.
Remember that the second midterm exam will be one week from today, on Monday, May 5. See the review problems from last Monday.
Here is another time zone web application. This version uses two web services and one of them is called by a JavaScript XMLHttpRequest in the web app's web page (try converting the XMLHttpRequest into a call to the fetch api). Look at the Readme.txt file in each of the folders.
To run this web app you need to unzip the first zip file and copy the resulting folder into the root folder of the web server. Then unzip the second zip file and compile and run the web server that is in that folder (that web server runs the two web services). Then start the web server that hosts the web applications.
Here is the simple time zone web application that we looked at in class on Monday. Look at the Readme.txt file in the folder. To run the app you need to unzip the zip file and copy the resulting folder into the root folder of the web server. Then start the web server.
Here is the time zone web application that we wrote in class today along with the "web service" that this version of the web application uses. Look at the Readme.txt file in each of the folders.
To run this web app you need to unzip the first zip file and copy the resulting folder into the root folder of the web server. Then unzip the second zip file and compile and run the web server that is in that folder (that web server runs the web service). Then start the web server that hosts the web application.
The second midterm exam will be two weeks from today, on Monday, May 5, as specified by the university's final examschedule.
The exam will be over the sample code listed below and the material from these previous reading assignments.
Read the following two introductions to AJAX, XMLHttpRequest, fetch (these three terms mean, more or less, the same thing, a way for programs to communicate using HTTP).
The following folder contains HTTP servers that implement the HTTP POST method. We will start to look at the details of how the server code implements the POST method for an HTML form.
We will continue to look at the differences between static and dynamic web pages. The following folder contains HTTP servers that implement the POST method, which lets us consider another aspect of dynamic web pages.
Today we will look at how HTTP implements persistent connections, and then we will start to look at the difference between a static and a dynamic web page.
To talk about HTTP and how it is used by web browsers and servers, we need to be familiar with the basics of web page technology, HTML, CSS, and JavaScript. Here are a few basic introductions.
Here is a simplified grammar for HTTP that's adapted from Illustrated Guide to HTTP. This syntax describes the language spoken by an HTTP client-server pair in the yellow box of the socket API.
Remember that the first midterm exam is one week from today, on March 5. Below are all the exam review problems including the network programming material.
They help explain how a client-server pair can coordinate the reversing of the read/write roles in this flowchart. They reverse roles when one reaches the "out of data" to send to the other.
The programs in this folder let us do more experiments with how clients and servers communicate with each other.
Remember that the first midterm exam is two weeks from today, on March 5. Below are the updated exam review problems including the network programming material.
The first midterm exam is three weeks from today, on March 5. Below are exam review problems for the material that we have covered so far (Java I/O, byte streams, data formats, character encodings). Next week there will be some more review problems about network programming.
Here is another chapter about Java I/O classes. This reference has a good explanation of Java's use of the decoratorpattern in the design of the stream classes.
Here are some books that we will use as references this semester. We will only need one or two chapters from each book. You should be able to download a pdf of each book (or individual chapters) while you are on campus.