[tcljava-user] tcl/java and threading questions
Brought to you by:
mdejong
From: hwachung f. <hc...@ya...> - 2009-05-02 00:40:20
|
I have a java app that evals a tcl script using tclblend. The tcl script at different places calls java as well, using again tclblend, to initiate http/s connections with a server. It also creates a few slave interpreters and runs the code (calling out to the server) in these slave interpreters periodically using tcl events. I would like to add threading to this app to improve performance, especially to replace the Tcl events. I find very little information on this subject such as thread safety of tclblend, Tcl threading, what to look out for, etc. I would like to create a few Java threads in the main java program and have different pieces of the curreent Tcl script run in different threads. I have read that each Tcl thread needs its own interpreter, so Java thread probably is the same. Has anyone done something like this before? Am I looking for trouble trying to do this -- especially there is so little information about these things in general. Thanks. Charles |