I have programmed with threads for years on the dark side, key points are
- very steep learning curve
- program has to be designed before writing
- potential dead locks have to be identified before coding
- timeout mechinism to over come unexpected deadlocks with logging to simplify
debugging and head scratching
- local and global variables and methods of accessing the same need to be
clearly defined
- cannot multi thread naturally single threaded processes like reading a
keyboard with a user
don't laugh took ages to work out what was going on between two
separate modules when
they were merged into a single program.
- most library code is not writen to be multithreaded included so called
multithread libraries
- database access can be very problematic as connection count can get out of
hand very quickly,
most database are accessed using libraries - see above
Maurice
I like
"... a folk definition of insanity is to do the same thing over and over again
and to expect the results to be different. By this definition, we in fact
require that programmers of multithreaded systems be insane. Were they sane,
they could not understand their programs."
Roy.