From: Francis Cianfrocca Date: 2006-10-06T23:06:50+09:00 Subject: Re: rb_funcall() Ruby code callback invoked from within a native thread? ------=_Part_29882_14756794.1160143606402 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline On 10/6/06, Serge Kruppa wrote: We solved the binary-gem issues with Windows quite a while ago, but have yet to release new binary gems. I'll send you one by private email. Some new features went into EM this week so we really need to get a new release up there. (Unfortunately rubyforge is down at the moment.) Once Rubyforge is back, you can sync to the current EM source code and try your Windows compilation. I know we've tested successfully on VC7, VC2003 and 2005 Express. However (and I'm not the biggest expert on this subject- Austin, are you reading this?) I think the consensus view is that Ruby extensions should only be compiled on VC6 in order to stay compatible with Ruby itself. What that means for EM on Windows is that published binary gems (which are always compiled with VC6) will be the way to go. Especially since production Windows servers generally don't have compilers installed. Another thing we've done recently is to add a pure-Ruby implementation of the EM functionality. EM code will degrade transparently to pure-Ruby whenever you run it in an environment that doesn't have the compiled extension for whatever reason. Performance is roughly half as good as compiled with really large loads. On small loads you might not notice a difference. 3) Another person in the team reported the same problem under Windows > (EventMachine 0.5.2) that I saw under Linux when running EM inside a > thread: > > EW> There is one serious issue left. The Event Machine udp server that is > used to replace the callbacks from the C native code to the ruby code dies > after processing just one message. Apparently this has to do with the > necessity of it running in the main thread. The main thread in the windows > program is however used by the windows gui event loop. Probably the best > approach is to use a simple udp server, just like in the java version. I want to know more about this UDP-server consuming only one message. It's probably a simple coding problem. Can you send me a test case by private email that exhibits the problem? ------=_Part_29882_14756794.1160143606402--