Can Guava's AbstractExecutionThreadService be reused?
As far as I can tell, once the run() method of AbstractExecutionThreadService stops, it can't be started again. Is that correct?
I have a service that extends AbstractExecutionThreadService. In my tests I want to start this service, use it, stop it, then start it again. Any suggestions what I开发者_StackOverflow社区 can/should do to achieve this while using AbstractExecutionThreadService or AbstractService?
Service.start() states that a stopped Service
may not be restarted. I'd say just create a new instance of your service and start it each time.
精彩评论