This week's book giveaway is in the OCAJP 8 forum.
We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line!
See this thread for details.
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Thread priority Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of OCA Java SE 8 Programmer I Study Guide this week in the OCAJP 8 forum!
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Thread priority" Watch "Thread priority" New topic

Thread priority

Angela Narain
Ranch Hand

Joined: Apr 14, 2001
Posts: 327
Whenever a new Thread is created it get Normal Priority (5)
Is this right ?
anita narula

Joined: Nov 28, 2000
Posts: 10
No, it is not right. If the newly created thread is not set a priority in the constructor, then it gets the priority of the thread that created it.
Ash sav
Ranch Hand

Joined: Apr 14, 2001
Posts: 55
I agree with Angela.
If no explicity thread priority is specified for a thread, it is given the default priority of 5.Thread inherits the priority of its parent thread.
Hope this helps.
I agree. Here's the link:
subject: Thread priority
It's not a secret anymore!