Route threads cannot be interrupted or stopped by the user if they are currently in one of the following states, and have been so for less than 1 minute:

  • Stopping.
  • Delivering.
  • Pulling from Input Queue.
  • Routing message.

Any attempt to stop or interrupt a route thread in one of these conditions will fail. The threads page is reloaded with an error message indicating the problem.

Interrupting a route execution or collector thread will cause the current message to be aborted. However, the thread continues and will immediately pick up the next message for processing (this could well be the message that it was previously processing if the route is still running).

Stopping a route execution or collector thread will cause the current message to be aborted, and the thread will exit. The route execution framework will then recreate a new thread to take its place.

 

Field/Action

Description

Thread Name

The internal thread name.

State

The thread state. Route execution threads can be in the following states:

  • Waiting for message.
  • Pulling from input queue.
  • Delivering.
  • Property extraction.
  • Adding to message collector.
  • Filtering message.
  • Routing message.
  • Route execution finished.
  • Sleep (indicates the route execution thread enters sleep mode as there are currently no messages can be processed on this route).

Route

The route the thread is currently running on. This is a hyperlink, or blank if the thread is not currently processing on any particular route.

Filter

The filter the thread is currently running on. This is a hyperlink, or blank if the thread is not currently processing on any particular filter.

Time in State

The amount of time the thread has been in its current state:

  • < 1 second - if less than a second.
  • The number of seconds - if less than a minute.
  • The number of minutes - if less than an hour.
  • The number of hours - if greater than an hour.

Thread Actions

  • Stack Trace - Opens a popup window showing a stack trace for the thread. A popup window is used to allow multiple stack traces of different threads to open simultaneously, without having to pre-generate the stack traces before displaying this page.
  • Interrupt - Interrupts the thread. You must confirm this action. This sets a flag on the thread letting it know that it has been interrupted. If the thread is blocked from performing some operation, it normally wakes up immediately and processes the interrupt. If the thread is busy, it may not notice the interrupt.

    While Rhapsody handles interrupts correctly, examples for existing Java code have shown incorrect ways of doing this. If you write a custom component that does not handle interrupts correctly, then it may do nothing.

    Interrupts are generally ignored if the thread is blocked within native code.

  • Terminate - Stops the thread. You must confirm this action. This calls the Java Thread.stop() method. This does not terminate the thread immediately, but causes it to throw ThreadDeath internally. This will almost always break out of any Java code, however, it is not likely to have an effect if the thread is stuck within native code.

    Rhapsody will automatically create a new thread to take the place of the thread that has been stopped.