Assignment#2 is marked

Apparently second assignment has been quite challenging as only five submissions were received. It's been marked and all of them have passed the assignment. Source code of any of the submissions can be obtained on the anti-plagiarism system report.

Torrents are good


Downloading large files using P2P technology can be quite convenient. As an example I've uploaded the ISO image of Graduation Ceremony DVD to Mininova. These guys are now prevented by a court order to distribute copyrighted contents. However there is no problem if the contents is public domain or posted by the rights holder. So here you have the torrent file.

If you did not graduate this year and therefore missed the ceremony, now you can have a look at it.

Class source code

Today we talked about Multi-thread servers and how we can create them easily in Java.

There are the three examples I wrote.

And let me correct myself: The first implementation of synchronized methods (using inc and dec methods for the simultaneous client counter) is as good as the last one (using just inc) as it is explained in here.Enlace

Excellence in Teaching Awards 2009

I've been granted an Excellence in Teaching award from the local government. Among other things lecturing in English (or other foreign languages) and having high-marks on student surveys of teaching were topics assessed.

Now it is time to look around and to thank all the people that made this possible: from my colleagues who share an interest on teaching to my students who keep on asking questions. From all of them I learn a lot every day.

I'm also grateful for my University and government that through various programs have supported different visits and stays at foreign universities.

And last, but not least, to my dear family and friends who have always been there for me.

For all of these I'm grateful.

Assignment#1 report


Not that the results are very bad but I want you to know that measures are taken to keep you all honest.


The following report checks the similarities between all of your submitted assignments.

Class problem

A 4-MByte file is transferred between two computers linked by a router. Each link is 100 Mbps and 100 meters long. Signal propagates at 85% the speed of light. TCP is used for the transfer with MSS=1460 bytes and Receive window is 2048 bytes. How long does it take for the transfer to complete?

Assume only data and TCP headers are transmitted. Assume TCP acknowledgments transmission and queuing delay are negligible. Assume TCP uses delayed acknowledgments. Assume no transmission errors happen and no congestion control is used. Assume TCP connection already established.

For solution OpenOffice's spreadsheet click on this entry title.


Or...


No thanks, I prefer to shot myself on the foot than to use OpenOffice.

Solution to assignment#1

As you have asked me for a solution I'm providing you mine.

You can see that as soon as a client does not provide expected command it is kicked out.

This server won't accept multiple messages sent over the same connection (nor it was required).

An alternative implementation using a finite state machine for the implementation is shown in this other solution.