Java Thread&Net demo