This content has been marked as final.
Show 2 replies
-
1. Re: refactor code out of ExecuteJobThread in Command
tom.baeyens Jun 5, 2007 10:12 AM (in response to camunda)managing threads on the other side of a session facade is not a good thing.
if you look at the job executor as a component, you could think of commands like start-new-thread and stop-thread or set-nbr-of-thread. but still the threads would be managed by the component, not the actual command.
hmmm... this reasoning is not really (thread?)-safe :-)
probably it depends on what you want to do. but i don't see yet a use case in which you want to manage the job executor. i would think it is always a deployment kind of thing.
another aspect is that you can also turn it around. you could just use the JobExecutorThread in the command in stead of the other way round.
just thinking out loud here. i didn't really see yet where you want to take it. -
2. Re: refactor code out of ExecuteJobThread in Command
camunda Jun 5, 2007 10:16 AM (in response to camunda)
another aspect is that you can also turn it around. you could just use the JobExecutorThread in the command in stead of the other way round.
Actually, I tried this. But it is not easy to leave out the Threading in the current implementation.
Maybe a solution would also be, to push some code for the Job-Execution in another class (or the ScheduleSession maybe?), so the JobEexecutorThread gets much easier and I can build a Command using the same code.