#565 Manage Running Method/Threads

None
unread
nobody
None
none
1
2014-02-11
2013-11-28
David Ashley
No

One of the problems I have with the REPLY instruction is that there is no way for the main process/thread to manage methods running on threads. You can not get a list if the running threads and there is no way to tell a method thread from any other type of thread that may have been spawned from an external library.

So I think that a global list of running threads/methods needs to be maintained by the ooRexx run time. If this is not possible then the REPLY instruction should be modified in such a way that it is possible for it to return the new threadID of the method to the caller (currently the thread is spawned after the REPLY instruction executes so it is not possible to return the new threadID).

Discussion

  • Mark Harsen
    Mark Harsen
    2014-02-11

    I would really like to see a way that we could get these threadIDs and furthermore be able to monitor and cancel them. I have written a rather large multithreaded network management server that sometimes gets a .console thread hung for various reasons. While I have mainly dealt with such implications, the ability to start a thread via a method's reply, monitor usage (such as CPU consumption), and especially the ability to cancel a rogue thread would simply be awesome!

    Thanks, -Mark

     


Anonymous


Cancel   Add attachments