Closed lscarval closed 9 years ago
Refer this thread for more info: https://groups.google.com/forum/?hl=en#!topic/repo-discuss/HvsppnIzg8A
I don't see a Gerrit 2.11.1 release yet? Hmmm... looks like they forgot to add it at https://code.google.com/p/gerrit/ . Seems to be here, though. Not good to remove a public function in jgit. It's called from deep within Gitblit. I'll see what I can do...
@tomaswolf the problem is in GitBlit and not in the plugin. Needs to be merged in GitBlit 1.7.0-SNAPSHOT. I doubt that @gitblit wants to apply the JGit 4.0 porting to 1.6.0 branch.
I know.
The problem has manifold causes:
Anyway, @lscarval: give release v2.11.1.162.1 a try. That fixes this problem; worked fine in my tests. Please do test, too (not just starting Gerrit, but also the functionality of the plugin), and report back here whether or not it works for you.
The server started successfully with Gerrit v2.11.1 and all functionalities are working as expected with plugin release v2.11.1.162.1. I haven't found any regressions up until now. Thanks
Thanks for the feedback!
GitBlit plugin version 2.11.162.3 prevents Gerrit v2.11.1 to start. See the error_log stacktrace below.
According to Luca, removing the release() method and using close() was the change made to fix the memory leak.
The plugin must be updated accordingly.
[2015-06-12 10:20:40,704] WARN org.eclipse.jetty.util.component.AbstractLifeCycle : FAILED o.e.j.s.ServletContextHandler@7b7f0be3{/,file:/home/gerrit2/review_site/tmp/gerrit_860001898783523603_app/gerrit_war/,STARTING}: java.lang.NoSuchMethodError: org.eclipse.jgit.treewalk.TreeWalk.release()V java.lang.NoSuchMethodError: org.eclipse.jgit.treewalk.TreeWalk.release()V at com.gitblit.utils.JGitUtils.getByteContent(JGitUtils.java:776) at com.gitblit.utils.JGitUtils.getSparkleshareId(JGitUtils.java:2141) at com.gitblit.manager.RepositoryManager.loadRepositoryModel(RepositoryManager.java:952) at com.gitblit.manager.RepositoryManager.getRepositoryModel(RepositoryManager.java:715) at com.gitblit.manager.RepositoryManager.configureCommitCache(RepositoryManager.java:1943) at com.gitblit.manager.RepositoryManager.start(RepositoryManager.java:165) at com.gitblit.manager.RepositoryManager.start(RepositoryManager.java:102) at com.gitblit.servlet.GitblitContext.startManager(GitblitContext.java:247) at com.gitblit.servlet.GitblitContext.configureContext(GitblitContext.java:186) at com.gitblit.servlet.GitblitContext.contextInitialized(GitblitContext.java:131) at com.googlesource.gerrit.plugins.gitblit.GerritWicketFilter.init(GerritWicketFilter.java:94) at com.google.inject.servlet.FilterDefinition.init(FilterDefinition.java:112) at com.google.inject.servlet.ManagedFilterPipeline.initPipeline(ManagedFilterPipeline.java:99) at com.google.inject.servlet.GuiceFilter.init(GuiceFilter.java:220) at com.google.gerrit.httpd.plugins.HttpPluginServlet.load(HttpPluginServlet.java:187) at com.google.gerrit.httpd.plugins.HttpPluginServlet.install(HttpPluginServlet.java:161) at com.google.gerrit.httpd.plugins.HttpPluginServlet.init(HttpPluginServlet.java:141) at com.google.inject.servlet.ServletDefinition.init(ServletDefinition.java:119) at com.google.inject.servlet.ManagedServletPipeline.init(ManagedServletPipeline.java:82) at com.google.inject.servlet.ManagedFilterPipeline.initPipeline(ManagedFilterPipeline.java:103) at com.google.inject.servlet.GuiceFilter.init(GuiceFilter.java:220) at org.eclipse.jetty.servlet.FilterHolder.initialize(FilterHolder.java:138) at org.eclipse.jetty.servlet.ServletHandler.initialize(ServletHandler.java:852) at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:298) at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:741) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:132) at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:114) at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:61) at org.eclipse.jetty.server.handler.RequestLogHandler.doStart(RequestLogHandler.java:140) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:132) at org.eclipse.jetty.server.Server.start(Server.java:387) at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:114) at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:61) at org.eclipse.jetty.server.Server.doStart(Server.java:354) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) at com.google.gerrit.pgm.http.jetty.JettyServer$Lifecycle.start(JettyServer.java:124) at com.google.gerrit.lifecycle.LifecycleManager.start(LifecycleManager.java:74) at com.google.gerrit.pgm.Daemon.start(Daemon.java:292) at com.google.gerrit.pgm.Daemon.run(Daemon.java:204) at com.google.gerrit.pgm.util.AbstractProgram.main(AbstractProgram.java:64) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at com.google.gerrit.launcher.GerritLauncher.invokeProgram(GerritLauncher.java:166) at com.google.gerrit.launcher.GerritLauncher.mainImpl(GerritLauncher.java:93) at com.google.gerrit.launcher.GerritLauncher.main(GerritLauncher.java:50) at Main.main(Main.java:25) [2015-06-12 10:20:40,705] WARN org.eclipse.jetty.util.component.AbstractLifeCycle : FAILED org.eclipse.jetty.server.handler.RequestLogHandler@29dbcdf9: java.lang.NoSuchMethodError: org.eclipse.jgit.treewalk.TreeWalk.release()V java.lang.NoSuchMethodError: org.eclipse.jgit.treewalk.TreeWalk.release()V at com.gitblit.utils.JGitUtils.getByteContent(JGitUtils.java:776) at com.gitblit.utils.JGitUtils.getSparkleshareId(JGitUtils.java:2141) at com.gitblit.manager.RepositoryManager.loadRepositoryModel(RepositoryManager.java:952) at com.gitblit.manager.RepositoryManager.getRepositoryModel(RepositoryManager.java:715) at com.gitblit.manager.RepositoryManager.configureCommitCache(RepositoryManager.java:1943) at com.gitblit.manager.RepositoryManager.start(RepositoryManager.java:165) at com.gitblit.manager.RepositoryManager.start(RepositoryManager.java:102) at com.gitblit.servlet.GitblitContext.startManager(GitblitContext.java:247) at com.gitblit.servlet.GitblitContext.configureContext(GitblitContext.java:186) at com.gitblit.servlet.GitblitContext.contextInitialized(GitblitContext.java:131) at com.googlesource.gerrit.plugins.gitblit.GerritWicketFilter.init(GerritWicketFilter.java:94) at com.google.inject.servlet.FilterDefinition.init(FilterDefinition.java:112) at com.google.inject.servlet.ManagedFilterPipeline.initPipeline(ManagedFilterPipeline.java:99) at com.google.inject.servlet.GuiceFilter.init(GuiceFilter.java:220) at com.google.gerrit.httpd.plugins.HttpPluginServlet.load(HttpPluginServlet.java:187) at com.google.gerrit.httpd.plugins.HttpPluginServlet.install(HttpPluginServlet.java:161) at com.google.gerrit.httpd.plugins.HttpPluginServlet.init(HttpPluginServlet.java:141) at com.google.inject.servlet.ServletDefinition.init(ServletDefinition.java:119) at com.google.inject.servlet.ManagedServletPipeline.init(ManagedServletPipeline.java:82) at com.google.inject.servlet.ManagedFilterPipeline.initPipeline(ManagedFilterPipeline.java:103) at com.google.inject.servlet.GuiceFilter.init(GuiceFilter.java:220) at org.eclipse.jetty.servlet.FilterHolder.initialize(FilterHolder.java:138) at org.eclipse.jetty.servlet.ServletHandler.initialize(ServletHandler.java:852) at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:298) at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:741) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:132) at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:114) at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:61) at org.eclipse.jetty.server.handler.RequestLogHandler.doStart(RequestLogHandler.java:140) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:132) at org.eclipse.jetty.server.Server.start(Server.java:387) at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:114) at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:61) at org.eclipse.jetty.server.Server.doStart(Server.java:354) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) at com.google.gerrit.pgm.http.jetty.JettyServer$Lifecycle.start(JettyServer.java:124) at com.google.gerrit.lifecycle.LifecycleManager.start(LifecycleManager.java:74) at com.google.gerrit.pgm.Daemon.start(Daemon.java:292) at com.google.gerrit.pgm.Daemon.run(Daemon.java:204) at com.google.gerrit.pgm.util.AbstractProgram.main(AbstractProgram.java:64) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at com.google.gerrit.launcher.GerritLauncher.invokeProgram(GerritLauncher.java:166) at com.google.gerrit.launcher.GerritLauncher.mainImpl(GerritLauncher.java:93) at com.google.gerrit.launcher.GerritLauncher.main(GerritLauncher.java:50) at Main.main(Main.java:25) [2015-06-12 10:20:40,708] INFO org.eclipse.jetty.server.ServerConnector : Started ServerConnector@3c2575e9{HTTP/1.1}{0.0.0.0:8089} [2015-06-12 10:20:40,709] WARN org.eclipse.jetty.util.component.AbstractLifeCycle : FAILED org.eclipse.jetty.server.Server@e2c73cd: java.lang.NoSuchMethodError: org.eclipse.jgit.treewalk.TreeWalk.release()V java.lang.NoSuchMethodError: org.eclipse.jgit.treewalk.TreeWalk.release()V at com.gitblit.utils.JGitUtils.getByteContent(JGitUtils.java:776) at com.gitblit.utils.JGitUtils.getSparkleshareId(JGitUtils.java:2141) at com.gitblit.manager.RepositoryManager.loadRepositoryModel(RepositoryManager.java:952) at com.gitblit.manager.RepositoryManager.getRepositoryModel(RepositoryManager.java:715) at com.gitblit.manager.RepositoryManager.configureCommitCache(RepositoryManager.java:1943) at com.gitblit.manager.RepositoryManager.start(RepositoryManager.java:165) at com.gitblit.manager.RepositoryManager.start(RepositoryManager.java:102) at com.gitblit.servlet.GitblitContext.startManager(GitblitContext.java:247) at com.gitblit.servlet.GitblitContext.configureContext(GitblitContext.java:186) at com.gitblit.servlet.GitblitContext.contextInitialized(GitblitContext.java:131) at com.googlesource.gerrit.plugins.gitblit.GerritWicketFilter.init(GerritWicketFilter.java:94) at com.google.inject.servlet.FilterDefinition.init(FilterDefinition.java:112) at com.google.inject.servlet.ManagedFilterPipeline.initPipeline(ManagedFilterPipeline.java:99) at com.google.inject.servlet.GuiceFilter.init(GuiceFilter.java:220) at com.google.gerrit.httpd.plugins.HttpPluginServlet.load(HttpPluginServlet.java:187) at com.google.gerrit.httpd.plugins.HttpPluginServlet.install(HttpPluginServlet.java:161) at com.google.gerrit.httpd.plugins.HttpPluginServlet.init(HttpPluginServlet.java:141) at com.google.inject.servlet.ServletDefinition.init(ServletDefinition.java:119) at com.google.inject.servlet.ManagedServletPipeline.init(ManagedServletPipeline.java:82) at com.google.inject.servlet.ManagedFilterPipeline.initPipeline(ManagedFilterPipeline.java:103) at com.google.inject.servlet.GuiceFilter.init(GuiceFilter.java:220) at org.eclipse.jetty.servlet.FilterHolder.initialize(FilterHolder.java:138) at org.eclipse.jetty.servlet.ServletHandler.initialize(ServletHandler.java:852) at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:298) at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:741) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:132) at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:114) at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:61) at org.eclipse.jetty.server.handler.RequestLogHandler.doStart(RequestLogHandler.java:140) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:132) at org.eclipse.jetty.server.Server.start(Server.java:387) at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:114) at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:61) at org.eclipse.jetty.server.Server.doStart(Server.java:354) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) at com.google.gerrit.pgm.http.jetty.JettyServer$Lifecycle.start(JettyServer.java:124) at com.google.gerrit.lifecycle.LifecycleManager.start(LifecycleManager.java:74) at com.google.gerrit.pgm.Daemon.start(Daemon.java:292) at com.google.gerrit.pgm.Daemon.run(Daemon.java:204) at com.google.gerrit.pgm.util.AbstractProgram.main(AbstractProgram.java:64) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at com.google.gerrit.launcher.GerritLauncher.invokeProgram(GerritLauncher.java:166) at com.google.gerrit.launcher.GerritLauncher.mainImpl(GerritLauncher.java:93) at com.google.gerrit.launcher.GerritLauncher.main(GerritLauncher.java:50) at Main.main(Main.java:25) [2015-06-12 10:20:40,709] ERROR com.google.gerrit.pgm.Daemon : Unable to start daemon java.lang.NoSuchMethodError: org.eclipse.jgit.treewalk.TreeWalk.release()V at com.gitblit.utils.JGitUtils.getByteContent(JGitUtils.java:776) at com.gitblit.utils.JGitUtils.getSparkleshareId(JGitUtils.java:2141) at com.gitblit.manager.RepositoryManager.loadRepositoryModel(RepositoryManager.java:952) at com.gitblit.manager.RepositoryManager.getRepositoryModel(RepositoryManager.java:715) at com.gitblit.manager.RepositoryManager.configureCommitCache(RepositoryManager.java:1943) at com.gitblit.manager.RepositoryManager.start(RepositoryManager.java:165) at com.gitblit.manager.RepositoryManager.start(RepositoryManager.java:102) at com.gitblit.servlet.GitblitContext.startManager(GitblitContext.java:247) at com.gitblit.servlet.GitblitContext.configureContext(GitblitContext.java:186) at com.gitblit.servlet.GitblitContext.contextInitialized(GitblitContext.java:131) at com.googlesource.gerrit.plugins.gitblit.GerritWicketFilter.init(GerritWicketFilter.java:94) at com.google.inject.servlet.FilterDefinition.init(FilterDefinition.java:112) at com.google.inject.servlet.ManagedFilterPipeline.initPipeline(ManagedFilterPipeline.java:99) at com.google.inject.servlet.GuiceFilter.init(GuiceFilter.java:220) at com.google.gerrit.httpd.plugins.HttpPluginServlet.load(HttpPluginServlet.java:187) at com.google.gerrit.httpd.plugins.HttpPluginServlet.install(HttpPluginServlet.java:161) at com.google.gerrit.httpd.plugins.HttpPluginServlet.init(HttpPluginServlet.java:141) at com.google.inject.servlet.ServletDefinition.init(ServletDefinition.java:119) at com.google.inject.servlet.ManagedServletPipeline.init(ManagedServletPipeline.java:82) at com.google.inject.servlet.ManagedFilterPipeline.initPipeline(ManagedFilterPipeline.java:103) at com.google.inject.servlet.GuiceFilter.init(GuiceFilter.java:220) at org.eclipse.jetty.servlet.FilterHolder.initialize(FilterHolder.java:138) at org.eclipse.jetty.servlet.ServletHandler.initialize(ServletHandler.java:852) at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:298) at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:741) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:132) at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:114) at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:61) at org.eclipse.jetty.server.handler.RequestLogHandler.doStart(RequestLogHandler.java:140) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:132) at org.eclipse.jetty.server.Server.start(Server.java:387) at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:114) at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:61) at org.eclipse.jetty.server.Server.doStart(Server.java:354) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) at com.google.gerrit.pgm.http.jetty.JettyServer$Lifecycle.start(JettyServer.java:124) at com.google.gerrit.lifecycle.LifecycleManager.start(LifecycleManager.java:74) at com.google.gerrit.pgm.Daemon.start(Daemon.java:292) at com.google.gerrit.pgm.Daemon.run(Daemon.java:204) at com.google.gerrit.pgm.util.AbstractProgram.main(AbstractProgram.java:64) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at com.google.gerrit.launcher.GerritLauncher.invokeProgram(GerritLauncher.java:166) at com.google.gerrit.launcher.GerritLauncher.mainImpl(GerritLauncher.java:93) at com.google.gerrit.launcher.GerritLauncher.main(GerritLauncher.java:50) at Main.main(Main.java:25)