Daniel Berger
2006-Feb-20 01:39 UTC
[Win32utils-devel] Fwd: Win32::Daemon, Problems with service_stop
Anyone want to take a stab at this? I''ve brought it up before but it''s been a while. Dan Note: forwarded message attached. __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com -------------- next part -------------- An embedded message was scrubbed... From: "Luis Lavena" <luislavena at gmail.com> Subject: Win32::Daemon, Problems with service_stop Date: Sun, 19 Feb 2006 16:14:43 -0300 Size: 2641 Url: http://rubyforge.org/pipermail/win32utils-devel/attachments/20060219/1e4db8d0/attachment.eml
Park Heesob
2006-Feb-20 14:30 UTC
[Win32utils-devel] Fwd: Win32::Daemon, Problems with service_stop
Hi, On Sun, 19 Feb 2006 17:39:32 -0800 (PST), Daniel Berger wrote> Anyone want to take a stab at this? I''ve brought it > up before but it''s been a while. > > Dan > > Note: forwarded message attached. >As you know,the win32-service is multithreaded application. But, Ruby''s sleep or select is not compatible with the Thread of Windows. While executing sleep or select in ruby code,the other thread cannot do anything. To workaround this stopping problem, 1. Use loop of short sleep insthead of long sleep. ex) 10.times { sleep 1 } instead of sleep 10 2. Use nonblocking IO and socket. Regards, Park Heesob