Results 1 to 2 of 2

Thread: How to find out no. of threads operating in Spring Batch

  1. #1

    Lightbulb How to find out no. of threads operating in Spring Batch

    Hi ,
    I have created a sample code in spring batch to implement multithreading , but I am not sure how many threads are getting created .Is there a way to find it out .Is the attribute "throttle-limit" describe the no. of threads that is running ?

  2. #2
    Join Date
    Sep 2008
    Location
    Chicagoland, IL
    Posts
    346

    Default

    Assuming you are referring to using a multithreaded step. In this case, the throttle limit is one indicator of how many threads are running. The other indicator is the number of threads your TaskExecutor is configured to use (if it's using a thread pool for example). Typically, the number of threads running will be the least of these two values (if you set a thread pool to have 2 threads and throttle-limit to 4, you'll have 2 threads running and if you have a thread pool of 4 and a throttle-limit of 20 you'll have 4 running.
    Michael Minella
    Spring Batch Lead
    Author - Pro Spring Batch
    http://www.michaelminella.com
    Twitter: @MichaelMinella

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •