James Dinkel wrote: > Kaja Mohaideen wrote: >> We people are new team for ruby. we trying to pput multithreading in our >> code. how is it possible? we want to read a message from queue and >> process that message parellaly and finally insert the message to the DB. >> Can you give me the Idea please >> >> Regards >> Kaja Mohaideen.A >> Trichy > > Use the Thread class. Just be aware that Ruby 1.8.x uses green threads. > Ruby 1.9.x uses native threads. Ruby 1.9 has native threads, but they do not run in parallel and Ruby is still in charge of scheduling them (or allowing the OS to schedule them). - Charlie