Hi Alex, This is a good point indeed. This may be hard to fix as I'm afraid it may depend on the actual HTTP connector used. Which one is it in your case? Do you get the same behavior with other connectors?
Best regards, Jerome > -----Message d'origine----- > De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] De la > part de Alex Milowski > Envoyé : mardi 17 avril 2007 22:53 > À : [email protected] > Objet : stop() not stopping? > > I have a component (a class that extends Component) that I use for > my application. In my JUnit tests I start and stop the component > several times. The Component seems not to really be "stopped" after > the stop method returns. As such, the next test may fail because the > Component can't be started due to a port binding conflict. > > Now, if I put a wait between the tests, everything works fine. > > Is there some wait to wait for the server rundown? Stop must request > a thread to stop but I need to wait for the thread to join > the current thread > before continuing with my tests. > > FYI, inside my component's initialization I do: > > getServers().add(Protocol.HTTP, ipAddress, port); > > and then add a virtual host: > > getHosts().add(host); > > Do I need to do something special to ensure the server is > completely stopped? > > --Alex Milowski

