• Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: Critical Critical
    • None
    • Windows 7 64-bit, Running Jenkins as a Windows Service

      I'm actually trying to install another plugin (pathignore) that is dependent on the ruby-runtime plugin, and I keep receiving an exception when trying to install ruby-runtime (0.6).

      This happens on Windows 7 64-bit, running Jenkins as a service. This is reproducible on Jenkins version 1.443 and 1.442. The issue does not happen on my Jenkins instance that is running on Ubuntu Server 10.4, so it appears to be something related to Windows.

      The exception that occurs is the following:

      jenkins.InitReactorRunner$1 onTaskFailed
      SEVERE: Failed Loading plugin ruby-runtime
      hudson.util.IOException2: Failed to initialize
      at hudson.ClassicPluginStrategy.load(ClassicPluginStrategy.java:335)
      at hudson.PluginManager$2$1$1.run(PluginManager.java:294)
      at org.jvnet.hudson.reactor.TaskGraphBuilder$TaskImpl.run(TaskGraphBuilder.java:146)
      at org.jvnet.hudson.reactor.Reactor.runTask(Reactor.java:259)
      at jenkins.model.Jenkins$5.runTask(Jenkins.java:804)
      at org.jvnet.hudson.reactor.Reactor$2.run(Reactor.java:187)
      at org.jvnet.hudson.reactor.Reactor$Node.run(Reactor.java:94)
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      at java.lang.Thread.run(Unknown Source)
      Caused by: org.jruby.embed.EvalFailedException: (LoadError) no such file to load – haml
      at org.jruby.embed.internal.EmbedEvalUnitImpl.run(EmbedEvalUnitImpl.java:127)
      at org.jruby.embed.ScriptingContainer.runUnit(ScriptingContainer.java:1231)
      at org.jruby.embed.ScriptingContainer.runScriptlet(ScriptingContainer.java:1224)
      at org.kohsuke.stapler.jelly.jruby.haml.HamlLanguage.createContainer(HamlLanguage.java:28)
      at org.kohsuke.stapler.jelly.jruby.JRubyFacet.<init>(JRubyFacet.java:69)
      at ruby.RubyRuntimePlugin.registerJRubyFacet(RubyRuntimePlugin.java:38)
      at ruby.RubyRuntimePlugin.start(RubyRuntimePlugin.java:29)
      at hudson.ClassicPluginStrategy.startPlugin(ClassicPluginStrategy.java:343)
      at hudson.ClassicPluginStrategy.load(ClassicPluginStrategy.java:332)
      ... 9 more
      Caused by: org.jruby.exceptions.RaiseException: (LoadError) no such file to load – haml

      If there's any additional debug information I can add, I'll be glad to attach that information.

          [JENKINS-12094] ruby-runtime plugin fails to initialize

          I saw that the ruby-runtime plugin had updated to version 0.7 from 0.6 today, and still encountered the same result on Windows 7 64-bit.

          Adam Westhusing added a comment - I saw that the ruby-runtime plugin had updated to version 0.7 from 0.6 today, and still encountered the same result on Windows 7 64-bit.

          My understanding is that ruby is not even supported in Jenkins, see https://wiki.jenkins-ci.org/display/JENKINS/Jenkins+plugin+development+in+Ruby

          I think the best move is to rewrite it in Groovy. Jenkins is written in Java, that's kind of shooting it's own foot to use a scripting language too far from Java.

          Sebastien Tardif added a comment - My understanding is that ruby is not even supported in Jenkins, see https://wiki.jenkins-ci.org/display/JENKINS/Jenkins+plugin+development+in+Ruby I think the best move is to rewrite it in Groovy. Jenkins is written in Java, that's kind of shooting it's own foot to use a scripting language too far from Java.

          Sebastien, JRuby isn't far from Java. This is still broken for Windows Vista. Here's the error seen when trying to install the plugin without a restart:

          hudson.util.IOException2: Failed to dynamically deploy this plugin
          at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1259)
          at hudson.model.UpdateCenter$DownloadJob.run(UpdateCenter.java:1056)
          at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
          at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
          at java.util.concurrent.FutureTask.run(Unknown Source)
          at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
          at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
          at java.lang.Thread.run(Unknown Source)
          Caused by: java.io.IOException: Unable to delete C:\Program Files (x86)\Jenkins\plugins\ruby-runtime\WEB-INF\lib\jruby-complete-1.6.5.jar
          at hudson.Util.deleteFile(Util.java:243)
          at hudson.Util.deleteRecursive(Util.java:293)
          at hudson.Util.deleteContentsRecursive(Util.java:204)
          at hudson.Util.deleteRecursive(Util.java:284)
          at hudson.Util.deleteContentsRecursive(Util.java:204)
          at hudson.Util.deleteRecursive(Util.java:284)
          at hudson.Util.deleteContentsRecursive(Util.java:204)
          at hudson.Util.deleteRecursive(Util.java:284)
          at hudson.ClassicPluginStrategy.explode(ClassicPluginStrategy.java:411)
          at hudson.ClassicPluginStrategy.createPluginWrapper(ClassicPluginStrategy.java:117)
          at hudson.PluginManager.dynamicLoad(PluginManager.java:391)
          at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1255)
          ... 7 more

          The file C:\Program Files (x86)\Jenkins\plugins\ruby-runtime\WEB-INF\lib\jruby-complete-1.6.5.jar exists but Windows prevents the file from being deleted if a process is using it. It seems that Jenkins tries to load it which is why it's unable to be deleted.

          Matthew Wilson added a comment - Sebastien, JRuby isn't far from Java. This is still broken for Windows Vista. Here's the error seen when trying to install the plugin without a restart: hudson.util.IOException2: Failed to dynamically deploy this plugin at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1259) at hudson.model.UpdateCenter$DownloadJob.run(UpdateCenter.java:1056) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source) Caused by: java.io.IOException: Unable to delete C:\Program Files (x86)\Jenkins\plugins\ruby-runtime\WEB-INF\lib\jruby-complete-1.6.5.jar at hudson.Util.deleteFile(Util.java:243) at hudson.Util.deleteRecursive(Util.java:293) at hudson.Util.deleteContentsRecursive(Util.java:204) at hudson.Util.deleteRecursive(Util.java:284) at hudson.Util.deleteContentsRecursive(Util.java:204) at hudson.Util.deleteRecursive(Util.java:284) at hudson.Util.deleteContentsRecursive(Util.java:204) at hudson.Util.deleteRecursive(Util.java:284) at hudson.ClassicPluginStrategy.explode(ClassicPluginStrategy.java:411) at hudson.ClassicPluginStrategy.createPluginWrapper(ClassicPluginStrategy.java:117) at hudson.PluginManager.dynamicLoad(PluginManager.java:391) at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1255) ... 7 more The file C:\Program Files (x86)\Jenkins\plugins\ruby-runtime\WEB-INF\lib\jruby-complete-1.6.5.jar exists but Windows prevents the file from being deleted if a process is using it. It seems that Jenkins tries to load it which is why it's unable to be deleted.

          Code changed in jenkins
          User: Josh Stupplebeen
          Path:
          java-runtime/src/main/java/ruby/RubyPlugin.java
          http://jenkins-ci.org/commit/jenkins.rb/aec6c9854508becac1b12cfdd439ed373e640ad4
          Log:
          [FIXED JENKINS-12094][FIXED JENKINS-23071] Upgrading jRuby version to 1.7.16 fixes both of these issues, [FIXED JENKINS-25782] Replaced ASCII spaces with space characters, removed some unused imports

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Josh Stupplebeen Path: java-runtime/src/main/java/ruby/RubyPlugin.java http://jenkins-ci.org/commit/jenkins.rb/aec6c9854508becac1b12cfdd439ed373e640ad4 Log: [FIXED JENKINS-12094] [FIXED JENKINS-23071] Upgrading jRuby version to 1.7.16 fixes both of these issues, [FIXED JENKINS-25782] Replaced ASCII spaces with space characters, removed some unused imports

          Dougal McRae added a comment - - edited

          Is this definitely fixed?

          I get the below error when trying to install Ruby Runtime Plugin (Plugin Id 'ruby-runtime') v0.12 to Jenkins v1.609.1 running at localhost on Windows 7 64-bit (Jenkins is installed in 'C:\Program Files (x86)\Jenkins'). JRuby v1.7.19 is installed (in C:\jruby-1.7.19).

          java.io.IOException: Failed to dynamically deploy this plugin
          at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1322)
          at hudson.model.UpdateCenter$DownloadJob.run(UpdateCenter.java:1121)
          at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
          at java.util.concurrent.FutureTask.run(Unknown Source)
          at hudson.remoting.AtmostOneThreadExecutor$Worker.run(AtmostOneThreadExecutor.java:110)
          at java.lang.Thread.run(Unknown Source)
          Caused by: java.nio.file.FileSystemException: C:\Program Files (x86)\Jenkins\plugins\ruby-runtime\WEB-INF\lib\classes.jar: The process cannot access the file because it is being used by another process.

          at sun.nio.fs.WindowsException.translateToIOException(Unknown Source)
          at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source)
          at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source)
          at sun.nio.fs.WindowsFileSystemProvider.implDelete(Unknown Source)
          at sun.nio.fs.AbstractFileSystemProvider.delete(Unknown Source)
          at java.nio.file.Files.delete(Unknown Source)
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
          at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
          at java.lang.reflect.Method.invoke(Unknown Source)
          at hudson.Util.deleteFile(Util.java:247)
          at hudson.Util.deleteRecursive(Util.java:310)
          at hudson.Util.deleteContentsRecursive(Util.java:212)
          at hudson.Util.deleteRecursive(Util.java:301)
          at hudson.Util.deleteContentsRecursive(Util.java:212)
          at hudson.Util.deleteRecursive(Util.java:301)
          at hudson.Util.deleteContentsRecursive(Util.java:212)
          at hudson.Util.deleteRecursive(Util.java:301)
          at hudson.ClassicPluginStrategy.explode(ClassicPluginStrategy.java:522)
          at hudson.ClassicPluginStrategy.createPluginWrapper(ClassicPluginStrategy.java:166)
          at hudson.PluginManager.dynamicLoad(PluginManager.java:448)
          at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1318)
          ... 5 more

          Dougal McRae added a comment - - edited Is this definitely fixed? I get the below error when trying to install Ruby Runtime Plugin (Plugin Id 'ruby-runtime') v0.12 to Jenkins v1.609.1 running at localhost on Windows 7 64-bit (Jenkins is installed in 'C:\Program Files (x86)\Jenkins'). JRuby v1.7.19 is installed (in C:\jruby-1.7.19). java.io.IOException: Failed to dynamically deploy this plugin at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1322) at hudson.model.UpdateCenter$DownloadJob.run(UpdateCenter.java:1121) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at hudson.remoting.AtmostOneThreadExecutor$Worker.run(AtmostOneThreadExecutor.java:110) at java.lang.Thread.run(Unknown Source) Caused by: java.nio.file.FileSystemException: C:\Program Files (x86)\Jenkins\plugins\ruby-runtime\WEB-INF\lib\classes.jar: The process cannot access the file because it is being used by another process. at sun.nio.fs.WindowsException.translateToIOException(Unknown Source) at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source) at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source) at sun.nio.fs.WindowsFileSystemProvider.implDelete(Unknown Source) at sun.nio.fs.AbstractFileSystemProvider.delete(Unknown Source) at java.nio.file.Files.delete(Unknown Source) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at hudson.Util.deleteFile(Util.java:247) at hudson.Util.deleteRecursive(Util.java:310) at hudson.Util.deleteContentsRecursive(Util.java:212) at hudson.Util.deleteRecursive(Util.java:301) at hudson.Util.deleteContentsRecursive(Util.java:212) at hudson.Util.deleteRecursive(Util.java:301) at hudson.Util.deleteContentsRecursive(Util.java:212) at hudson.Util.deleteRecursive(Util.java:301) at hudson.ClassicPluginStrategy.explode(ClassicPluginStrategy.java:522) at hudson.ClassicPluginStrategy.createPluginWrapper(ClassicPluginStrategy.java:166) at hudson.PluginManager.dynamicLoad(PluginManager.java:448) at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1318) ... 5 more

          James Tanner added a comment - - edited

          I think I have also experienced this issue.
          I was able to reproduce it on a fresh Jenkins install, and after a bit of messing around I believe that its because Jenkins (and therefore the plugin) is installed on a path with spaces in it. Moving my test installation to C:\Jenkins seemed to allow the plugin to install.
          I was also able to confirm this fix on our build server that had the issue originally.

          James Tanner added a comment - - edited I think I have also experienced this issue. I was able to reproduce it on a fresh Jenkins install, and after a bit of messing around I believe that its because Jenkins (and therefore the plugin) is installed on a path with spaces in it. Moving my test installation to C:\Jenkins seemed to allow the plugin to install. I was also able to confirm this fix on our build server that had the issue originally.

          Ivan Yiu added a comment -

          I have the same issue installing the Capitomcat plugin.

           

           

          Ivan Yiu added a comment - I have the same issue installing the Capitomcat plugin.    

          Azizul Rehman added a comment -

          Manual installation of ruby-runtime plugin also fails on Windows 7 x64.
          Steps followed:
          1. Downloaded latest version of ruby-runtime.hpi
          2. Goto Jenkins--> pluginManager --> advanced --> Upload Plugin
          3. Browse to ruby-runtime.hpi
          4. Click Upload.

          Error encountered:

          java.nio.file.FileSystemException: C:\Program Files (x86)\Jenkins\plugins\ruby-runtime\WEB-INF\lib\classes.jar: The process cannot access the file because it is being used by another process.

          at sun.nio.fs.WindowsException.translateToIOException(Unknown Source)
          at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source)
          at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source)
          at sun.nio.fs.WindowsFileSystemProvider.implDelete(Unknown Source)
          at sun.nio.fs.AbstractFileSystemProvider.deleteIfExists(Unknown Source)
          at java.nio.file.Files.deleteIfExists(Unknown Source)
          at hudson.Util.tryOnceDeleteFile(Util.java:287)
          at hudson.Util.tryOnceDeleteRecursive(Util.java:364)
          at hudson.Util.tryOnceDeleteContentsRecursive(Util.java:383)
          at hudson.Util.tryOnceDeleteRecursive(Util.java:363)
          at hudson.Util.tryOnceDeleteContentsRecursive(Util.java:383)
          at hudson.Util.tryOnceDeleteRecursive(Util.java:363)
          at hudson.Util.tryOnceDeleteContentsRecursive(Util.java:383)
          at hudson.Util.tryOnceDeleteRecursive(Util.java:363)
          at hudson.Util.deleteRecursive(Util.java:341)
          Caused: java.io.IOException: Unable to delete 'C:\Program Files (x86)\Jenkins\plugins\ruby-runtime'. Tried 3 times (of a maximum of 3) waiting 0.1 sec between attempts.
          at hudson.Util.deleteRecursive(Util.java:346)
          at hudson.ClassicPluginStrategy.explode(ClassicPluginStrategy.java:604)
          at hudson.ClassicPluginStrategy.createPluginWrapper(ClassicPluginStrategy.java:167)
          at hudson.PluginManager.dynamicLoad(PluginManager.java:849)
          at hudson.PluginManager.dynamicLoad(PluginManager.java:814)
          at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1895)
          Caused: java.io.IOException: Failed to dynamically deploy this plugin
          at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1899)
          at hudson.model.UpdateCenter$DownloadJob.run(UpdateCenter.java:1656)
          at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
          at java.util.concurrent.FutureTask.run(Unknown Source)
          at hudson.remoting.AtmostOneThreadExecutor$Worker.run(AtmostOneThreadExecutor.java:110)
          at java.lang.Thread.run(Unknown Source)

          Azizul Rehman added a comment - Manual installation of ruby-runtime plugin also fails on Windows 7 x64. Steps followed: 1. Downloaded latest version of ruby-runtime.hpi 2. Goto Jenkins--> pluginManager --> advanced --> Upload Plugin 3. Browse to ruby-runtime.hpi 4. Click Upload. Error encountered: java.nio.file.FileSystemException: C:\Program Files (x86)\Jenkins\plugins\ruby-runtime\WEB-INF\lib\classes.jar: The process cannot access the file because it is being used by another process. at sun.nio.fs.WindowsException.translateToIOException(Unknown Source) at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source) at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source) at sun.nio.fs.WindowsFileSystemProvider.implDelete(Unknown Source) at sun.nio.fs.AbstractFileSystemProvider.deleteIfExists(Unknown Source) at java.nio.file.Files.deleteIfExists(Unknown Source) at hudson.Util.tryOnceDeleteFile(Util.java:287) at hudson.Util.tryOnceDeleteRecursive(Util.java:364) at hudson.Util.tryOnceDeleteContentsRecursive(Util.java:383) at hudson.Util.tryOnceDeleteRecursive(Util.java:363) at hudson.Util.tryOnceDeleteContentsRecursive(Util.java:383) at hudson.Util.tryOnceDeleteRecursive(Util.java:363) at hudson.Util.tryOnceDeleteContentsRecursive(Util.java:383) at hudson.Util.tryOnceDeleteRecursive(Util.java:363) at hudson.Util.deleteRecursive(Util.java:341) Caused: java.io.IOException: Unable to delete 'C:\Program Files (x86)\Jenkins\plugins\ruby-runtime'. Tried 3 times (of a maximum of 3) waiting 0.1 sec between attempts. at hudson.Util.deleteRecursive(Util.java:346) at hudson.ClassicPluginStrategy.explode(ClassicPluginStrategy.java:604) at hudson.ClassicPluginStrategy.createPluginWrapper(ClassicPluginStrategy.java:167) at hudson.PluginManager.dynamicLoad(PluginManager.java:849) at hudson.PluginManager.dynamicLoad(PluginManager.java:814) at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1895) Caused: java.io.IOException: Failed to dynamically deploy this plugin at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1899) at hudson.model.UpdateCenter$DownloadJob.run(UpdateCenter.java:1656) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at hudson.remoting.AtmostOneThreadExecutor$Worker.run(AtmostOneThreadExecutor.java:110) at java.lang.Thread.run(Unknown Source)

          Basil Crow added a comment -

          Basil Crow added a comment - See Deprecating non-Java plugins .

            Unassigned Unassigned
            westhusing Adam Westhusing
            Votes:
            8 Vote for this issue
            Watchers:
            12 Start watching this issue

              Created:
              Updated:
              Resolved: