[Jruby-devel] Rails working with webrick (mostly)

2006-06-13 Thread Thomas E Enebo
Here is a partial display of console to prove it (details follow): [Fuebo /opt/cookbook]$ ../workspace/jruby5/bin/jruby script/server webrick => Booting WEBrick... => Rails application started on http://0.0.0.0:3000 => Ctrl-C to shutdown server; call with --help for options [2006-06-13 22:06:31]

Re: [Jruby-devel] First error with script/server.

2006-06-13 Thread Thomas E Enebo
When I was playing with this stuff I just added the extra arg of the server I wanted started: jruby script/server webrick -Tom On Tue, 13 Jun 2006, Charles O Nutter defenestrated me: > >With the fastcgi nonsense commented out, the fcntl patch, and the >Socket/BasicSocket thing fixed,

Re: [Jruby-devel] First error with script/server.

2006-06-13 Thread Charles O Nutter
With the fastcgi nonsense commented out, the fcntl patch, and the Socket/BasicSocket thing fixed, script/server starts up and successfully serves the index page!!!And then it stops doing anything.But it's close! => Booting WEBrick...=> Rails application started on http://0.0.0.0:3000=> Ctrl-C to sh

Re: [Jruby-devel] Including RubyGems in the release

2006-06-13 Thread Charles O Nutter
I was hoping to avoid Jem and the Holograms references in the general releases of JRuby...but perhaps nostalgia sells? Seriously though, it does sound and look a lot nicer. Our "jirb" is perhaps the most comfortable prefixing of J...although renaming "jruby" to "juby" is perhaps asking for trouble.

Re: [Jruby-devel] First error with script/server.

2006-06-13 Thread Charles O Nutter
Fixed. SocketMetaClass needed the following:- extend BasicSocketMetaClass- pass the BasicSocket rubyclass as parentSocketLibrary needed to reorder creation of BasicSocketMetaClass and SocketMetaClass so Socket could extend BasicSocket. The extension in the .rb file doesn't work unless the classes a

Re: [Jruby-devel] Including RubyGems in the release

2006-06-13 Thread Zach
Very silly suggestion, but why not just call it jem? The one thing I worry about is trying to install gems that require compilation. The native MySQL bindings is a good example. Is jGems going to prompt saying why this can't be installed? Is the same going to hold true for dependencies? -ZachOn

Re: [Jruby-devel] First error with script/server.

2006-06-13 Thread Charles O Nutter
Perhaps this has something to do with it:irb(main):014:0> Socket.superclass=> ObjectNow we just need to figure out why that's happening :)On 6/13/06, Charles O Nutter <[EMAIL PROTECTED]> wrote: The Socket/BasicSocket dichotomy is certainly an interesting issue. It doesn't seem to be a simple issue

Re: [Jruby-devel] First error with script/server.

2006-06-13 Thread Charles O Nutter
The Socket/BasicSocket dichotomy is certainly an interesting issue. It doesn't seem to be a simple issue of singleton methods, since File's singleton methods work fine in extending classes:class F < Fileend F.dirnameĀ  => wrong number of arguments (i.e. it's finding it ok)So there's something odd ab

[Jruby-devel] First error with script/server.

2006-06-13 Thread Ola Bini
Well, so I've found the first thing that's a problem with script/server, at least on my win32-box. The server script first tries to determine which server to use. It does this by all different manners of fun tricks. This one: if RUBY_PLATFORM !~ /mswin/ && !silence_stderr { `lighttpd -version` }

[Jruby-devel] A little YARV teaser from JP

2006-06-13 Thread Charles O Nutter
A blog commenter pointed this out:http://redhanded.hobix.com/cult/rubyKaigi2006.htmlShort story:- YARV in Ruby 1.9.1, Christmas 2007 - Pure native threads- No continuationsOf course, that's a long time from now. I think our current track to get things "correct" and then implement the simplest nativ

Re: [Jruby-devel] WEBrick.

2006-06-13 Thread Thomas E Enebo
I had thought I had webrick working fairly well, but did not see the fcntl problem. It is cool we can support non-blocking. I can apply the patch (from your other thread) this evening (I am out of town on an unexpected business trip). -Tom On Tue, 13 Jun 2006, Ola Bini defenestrated me: >

[Jruby-devel] Some rails updates

2006-06-13 Thread Charles O Nutter
I committed a cleaner patch for rails/railties in docs/patches/rails; this one should apply correctly with your patch program of choice. I did patch -p0 < xxx and it appears to have worked fine.I also added a bogus Signal module and trap method to allow the rails script to run without error. It doe

Re: [Jruby-devel] Webrick, one again.

2006-06-13 Thread Charles O Nutter
I wouldn't be surprised if WEBrick is also using that timeout package. You could try commenting out all the threading weirdness in timeout.rb, and I'd bet the exceptions go away.Given that an InterruptedException is almost always going to mean a thread is being terminated in JRuby, it might be acce

[Jruby-devel] Webrick, one again.

2006-06-13 Thread Ola Bini
I seem to have been wrong, before. For the usual cases, WEBrick seems to work just fine. We do get those InterruptedErrors, though. I've managed to get it running as a static httpserver and also using ruby servlets and mount_proc. But if I manage to elicit a 404-error, WEBrick takes it way to pe

[Jruby-devel] WEBrick status.

2006-06-13 Thread Ola Bini
Hi I've managed to fix a working fcntl implementation that sets nonblocking io when asked to. Patch is attached. This makes a simple daytime server work flawlessly. When I scale this up and try something like this: require 'webrick' include WEBrick s = HTTPServer.new( :Port=> 2

[Jruby-devel] pay attention to H_Y_W_I Raking in the dough.

2006-06-13 Thread lhjjobkg irmlrkiyf
H Y W I . P K- H o l l y w o o d I n t e r m e d i a t e, Inc. We Strongly believe in this companies Performance, with its 5th stright day of climb Today was just the begining See Hot NEWS Just released as we mentioned yesterday , its still early S Y M B O L : H Y W I Current Price: $ 1.01 7

[Jruby-devel] WEBrick.

2006-06-13 Thread Ola Bini
Hi, It seems that it would be great fun to support WEBrick completely, wouldn't it? I tried this small example, a daytime server: require 'webrick' s = WEBrick::GenericServer.new( :Port => 2000 ) trap("INT"){ s.shutdown } s.start{|sock| sock.print(Time.now.to_s + "\r\n") } Alas, it actually