events-log not working in 2.15.2?

182 views
Skip to first unread message

Eberhard Beilharz

unread,
Jul 4, 2018, 1:05:17 PM7/4/18
to Repo and Gerrit Discussion
I just upgraded Gerrit to 2.15.2 after downloading the latest version of the plugins, and I did the offline migration to notesDb. Now the error_log shows that events-log fails to start:

[2018-07-04 18:57:35,948] [main] WARN  com.google.gerrit.server.plugins.PluginLoader : Cannot load plugin events-log
java.lang.NoSuchMethodError: com.google.gerrit.server.git.WorkQueue.createQueue(ILjava/lang/String;)Ljava/util/concurrent/ScheduledThreadPoolExecutor;
        at com.ericsson.gerrit.plugins.eventslog.EventQueue.start(EventQueue.java:35)
        at com.google.gerrit.lifecycle.LifecycleManager.start(LifecycleManager.java:92)
        at com.google.gerrit.server.plugins.ServerPlugin.startPlugin(ServerPlugin.java:251)
        at com.google.gerrit.server.plugins.ServerPlugin.start(ServerPlugin.java:192)
        at com.google.gerrit.server.plugins.PluginLoader.runPlugin(PluginLoader.java:486)
        at com.google.gerrit.server.plugins.PluginLoader.rescan(PluginLoader.java:415)
        at com.google.gerrit.server.plugins.PluginLoader.start(PluginLoader.java:322)
        at com.google.gerrit.lifecycle.LifecycleManager.start(LifecycleManager.java:92)
        at com.google.gerrit.pgm.Daemon.start(Daemon.java:351)
        at com.google.gerrit.pgm.Daemon.run(Daemon.java:258)
        at com.google.gerrit.pgm.util.AbstractProgram.main(AbstractProgram.java:61)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at com.google.gerrit.launcher.GerritLauncher.invokeProgram(GerritLauncher.java:223)
        at com.google.gerrit.launcher.GerritLauncher.mainImpl(GerritLauncher.java:119)
        at com.google.gerrit.launcher.GerritLauncher.main(GerritLauncher.java:63)
        at Main.main(Main.java:24)

Is this a know problem or is there a workaround?

Thanks,
Eberhard

Hector Oswaldo Caballero

unread,
Jul 4, 2018, 4:55:56 PM7/4/18
to Repo and Gerrit Discussion
Are you sure yo downloaded the right plugin version? I ask because I just deployed it on Gerri 2.15.2 and the plugin loads OK.

Am I missing somethig?

Luca Milanesio

unread,
Jul 4, 2018, 4:59:30 PM7/4/18
to Repo and Gerrit Discussion, Luca Milanesio, Hector Oswaldo Caballero
It is a known issue and Hugo fixed it in Gerrit 2.15.3 (not released yet though).

HTH

Luca.

Eberhard Beilharz

unread,
Jul 5, 2018, 4:47:53 AM7/5/18
to Repo and Gerrit Discussion

Thanks for your suggestion! Unfortunately it's still not working. I installed Gerrit 2.15.2-237-g28ab32a2b9 from the link and got events-log.jar from https://gerrit-ci.gerritforge.com/view/Plugins-stable-2.15/job/plugin-events-log-bazel-stable-2.15/7/artifact/bazel-genfiles/plugins/events-log/events-log.jar again. And it still fails with the same call stack!

I looked at the source code for both events-log and gerrit, and I don't understand why it's looking for a createQueue method that returns a ScheduledThreadPoolExecutor. The source code in events-log expects a ScheduledExecutorService, and Gerrit has a  public ScheduledExecutorService createQueue(int poolsize, String queueName) method - why doesn't this work???

I also tried with the docker image (https://hub.docker.com/r/gerritcodereview/gerrit/). Installation of the events-log plugin through plugin-manger doesn't work - it causes the button to change to FAILED (the same in my test installation). The console output only shows:

[2018-07-05 08:41:20,245] [HTTP-104] WARN  com.google.gerrit.server.plugins.PluginLoader : Plugin provides its own name: <events-log>, use it instead of the input name: <events-log.jar>
Jul 05, 2018 8:41:20 AM com.google.inject.servlet.GuiceFilter setPipeline
WARNING: Multiple Servlet injectors detected. This is a warning indicating that you have more than one GuiceFilter running in your web application. If this is deliberate, you may safely ignore this message. If this is NOT deliberate however, your application may not work as expected.

If I download the events-log manually and put it in the plugins folder of the docker container, I get the same NoSuchMethodError stack trace as with my test installation.

Luca Milanesio

unread,
Jul 5, 2018, 5:20:14 AM7/5/18
to Eberhard Beilharz, Luca Milanesio, Repo and Gerrit Discussion

On 5 Jul 2018, at 09:47, Eberhard Beilharz <e...@sil.org> wrote:


Thanks for your suggestion! Unfortunately it's still not working. I installed Gerrit 2.15.2-237-g28ab32a2b9 from the link and got events-log.jar from https://gerrit-ci.gerritforge.com/view/Plugins-stable-2.15/job/plugin-events-log-bazel-stable-2.15/7/artifact/bazel-genfiles/plugins/events-log/events-log.jar again. And it still fails with the same call stack!

I believe the problem was starting with a change on stable-2.14 that broken binary compatibility because of the createQueue() signature change.
The events-log plugin was built on the CI with the broken compatibility ... and that broke the ability to load it.

Then Gerrit was fixed, but possibly the plugin not rebuilt.

I've rebuilt the plugin, installed on top of Gerrit 2.15.<latest and greatest> and worked.

See below:
Plugins
  
Plugin NameSettingsVersionStatus
analytics1.0-1-g5a0cc4aEnabled
analytics-etl1.0-18-g706ffe6-SNAPSHOTEnabled
analytics-wizard23ee7149eda5ebafc73730cabeb6004bfd71d3dcEnabled
delete-projectv2.13-61-g8d6b23b122Enabled
events-logv2.13-66-ge95af940c6Enabled
gitblitv2.14-9-gd564d9cEnabled
github-plugin2.15.2Enabled
groovy-providerv2.15Enabled
high-availabilityca345c8-dirtyEnabled
javamelodyv2.14-40-g0c0f55671fEnabled
singleusergroupv2.15.2-1-g578bc67Enabled
warm-cache1.0Enabled

Powered by Gerrit Code Review (2.15.2-237-g28ab32a2b9) | Switch to New UI | Press '?' to view keyboard shortcuts

Hope this helps.

Luca.

-- 
-- 
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

--- 
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Eberhard Beilharz

unread,
Jul 5, 2018, 5:51:58 AM7/5/18
to Repo and Gerrit Discussion

YES! With the rebuilt plugin it works! Thanks!

Eberhard

Luca Milanesio

unread,
Jul 5, 2018, 6:05:47 AM7/5/18
to Eberhard Beilharz, Luca Milanesio, Repo and Gerrit Discussion

On 5 Jul 2018, at 10:51, Eberhard Beilharz <e...@sil.org> wrote:


YES! With the rebuilt plugin it works! Thanks!

Yeah, we have a CI issue actually: we *don't* automatically rebuild all the plugins when a new commit to Gerrit gets merged ... we don't have enough cloud capacity for it.
I typically trigger a rebuild anyway when a new release is out, so that a "refreshed" set of plugins is published ... but 2.15.3 isn't released yet :-(

Luca.


Eberhard
Reply all
Reply to author
Forward
0 new messages