Win a copy of Head First Go this week in the Go forum!
  • 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Bear Bibeault
  • Paul Clapham
  • Jeanne Boyarsky
Sheriffs:
  • Devaka Cooray
  • Junilu Lacar
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Ron McLeod
  • Tim Holloway
  • Claude Moore
  • Stephan van Hulst
Bartenders:
  • Winston Gutkowski
  • Carey Brown
  • Frits Walraven

Thread taking maximum time  RSS feed

 
Ranch Hand
Posts: 387
2
Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Suppose we have an application which spawns 50 threads. I want to figure out which thread is taking maximum amount of time. How can we extract this information?
 
Saloon Keeper
Posts: 9861
199
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
At runtime, or do you want to perform a test?
 
Vaibhav Gargs
Ranch Hand
Posts: 387
2
Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
At runtime in production. Can we do some kind of logging
 
Stephan van Hulst
Saloon Keeper
Posts: 9861
199
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You might want to instrument your code with ThreadMXBean.
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!