• 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
  • Bear Bibeault
  • Devaka Cooray
  • Liutauras Vilda
  • Jeanne Boyarsky
Sheriffs:
  • Knute Snortum
  • Junilu Lacar
  • paul wheaton
Saloon Keepers:
  • Ganesh Patekar
  • Frits Walraven
  • Tim Moores
  • Ron McLeod
  • Carey Brown
Bartenders:
  • Stephan van Hulst
  • salvin francis
  • Tim Holloway

Thread taking maximum time  RSS feed

 
Ranch Hand
Posts: 370
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?
 
Bartender
Posts: 9486
184
  • 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: 370
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
Bartender
Posts: 9486
184
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You might want to instrument your code with ThreadMXBean.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!