• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Ron McLeod
  • paul wheaton
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
  • Himai Minh
Bartenders:

how to implement a java thread???

 
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am a college student working at NIST (National Institute of Standards and Technology). I have a question that maybe someone can answer or perhaps can show me where I can possibly find an answer.

I am running a scenario that involves multiple beans with multiple message passing. Is there a way for two beans to send the same event at the same time. I believe that the use of the Java thread can perform this task, but I am not sure how to set it up. I want multiple beans to be able to launch multiple event concurrently. Java seams to work very sequentially and I have not been able to organize events so that they run parallel.

Does anyone have any advice. Any assistance would be greatly appreciated.

Thanks, Jesse Elder
 
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Try the Timer class introduced with jdk1.3. This can be used to sync up the two threads.Also you can use the notify method , such that one thread would notify the other before executing the bean operation.
 
Ranch Hand
Posts: 3244
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
MAnderson
Welcome to the Java Ranch, we hope you’ll enjoy visiting as a regular however,
your name is not in keeping with our naming policy here at the ranch. Please change your display name to an appropriate name as shown in the policy.
Thanks again and we hope to see you around the ranch!!
 
Jesse Elder
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I dont understand, this is my real name. Thanks Matt, I shall give it a try
Jesse Elder
 
Jesse Elder
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Matt, is there anyway that you can elaborate on your suggestion? Thanks for the help.
Jesse
 
reply
    Bookmark Topic Watch Topic
  • New Topic