buildr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vbo...@apache.org
Subject svn commit: r706504 - in /incubator/buildr/trunk/addon/buildr: drb.rb nailgun.rb
Date Tue, 21 Oct 2008 04:01:15 GMT
Author: vborja
Date: Mon Oct 20 21:01:13 2008
New Revision: 706504

URL: http://svn.apache.org/viewvc?rev=706504&view=rev
Log:
Moved notice to nailgun.rb.
Connecting to a dRuby server running on JRuby from RMI seems not to work all times, tell the
user to use nailgun.

Modified:
    incubator/buildr/trunk/addon/buildr/drb.rb
    incubator/buildr/trunk/addon/buildr/nailgun.rb

Modified: incubator/buildr/trunk/addon/buildr/drb.rb
URL: http://svn.apache.org/viewvc/incubator/buildr/trunk/addon/buildr/drb.rb?rev=706504&r1=706503&r2=706504&view=diff
==============================================================================
--- incubator/buildr/trunk/addon/buildr/drb.rb (original)
+++ incubator/buildr/trunk/addon/buildr/drb.rb Mon Oct 20 21:01:13 2008
@@ -168,17 +168,11 @@
         setup
         if RUBY_PLATFORM[/java/]
           require 'buildr/nailgun'
-          info ''
-          info 'Running in JRuby, a nailgun server will be started so that'
-          info 'you can use your nailgun client to invoke buildr tasks: '
-          info ''
-          info '  '+Nailgun.installed_bin.to_s
-          info ''
-          Buildr.application['nailgun:start'].invoke
+          Buildr.application['nailgun:drb'].invoke
         else
           run_server
+          DRb.thread.join
         end
-        DRb.thread.join
       end
       
       def with_config(remote)

Modified: incubator/buildr/trunk/addon/buildr/nailgun.rb
URL: http://svn.apache.org/viewvc/incubator/buildr/trunk/addon/buildr/nailgun.rb?rev=706504&r1=706503&r2=706504&view=diff
==============================================================================
--- incubator/buildr/trunk/addon/buildr/nailgun.rb (original)
+++ incubator/buildr/trunk/addon/buildr/nailgun.rb Mon Oct 20 21:01:13 2008
@@ -16,6 +16,7 @@
 
 require 'jruby'
 require 'rbconfig'
+require 'tmpdir'
 require 'buildr/drb'
 
 
@@ -197,12 +198,22 @@
         cp compiled_bin.to_s, task.to_s, :verbose => false
       end
 
+      task('drb-notice') do
+        info ''
+        info 'Running in JRuby, a nailgun server will be started so that'
+        info 'you can use your nailgun client to invoke buildr tasks: '
+        info ''
+        info '  '+Nailgun.installed_bin.to_s
+        info ''
+      end
+
+      task('drb' => ['drb-notice', 'start'])
+
       desc 'Start the nailgun server'
       task('start' => [installed_bin, artifact]) do |task|
         server_setup.call
         server = NGServer.new(nil, PORT)
         server.start
-        DRbApplication.run_server
       end
 
     end # ng_tasks



Mime
View raw message