Win a copy of Practical SVG this week in the HTML/CSS/JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Multithreading - only one thread works

 
jane june
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm trying to do multithreading in java but the thread that connects last, i.e the latest thread, is the only one that works. As for the previous threads, the code just gets stuck on reading (through data input stream. I also tried using buffered input stream but the problem didn't go away) from the server. It just hangs there. Can somebody explain why? What could be the possible reasons?

Hoping for a quick reply!

Thank you!
 
Henry Wong
author
Sheriff
Posts: 22542
109
C++ Chrome Eclipse IDE Firefox Browser Java jQuery Linux VI Editor Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

It may help a bit if you showed us some of the code (preferably isolated to where you think the issue is).

Henry
 
Campbell Ritchie
Marshal
Posts: 52632
119
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
And welcome to the Ranch

I think this question too difficult for “beginning” so I shall move it to our threads forum.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!