komoot / photon

an open source geocoder for openstreetmap data
Apache License 2.0
1.83k stars 278 forks source link

one of the gradle distributions does not run #791

Closed karussell closed 2 months ago

karussell commented 2 months ago

I tried the photon-version.zip distribution but it says:

./bin/photon
Exception in thread "main" java.lang.IllegalStateException: failed to load plugin - Plugin information:
Name: lang-painless
Description: An easy, safe and fast scripting language for Elasticsearch
Version: 5.6.16
Native Controller: false
 * Classname: org.elasticsearch.painless.PainlessPlugin due to jar hell
    at org.elasticsearch.plugins.PluginsService.loadBundles(PluginsService.java:380)
    at org.elasticsearch.plugins.PluginsService.<init>(PluginsService.java:141)
    at org.elasticsearch.node.Node.<init>(Node.java:313)
    at de.komoot.photon.elasticsearch.Server$MyNode.<init>(Server.java:68)
    at de.komoot.photon.elasticsearch.Server.start(Server.java:110)
    at de.komoot.photon.App.main(App.java:41)
Caused by: java.lang.IllegalStateException: jar hell!
class: META-INF.versions.9.module-info
jar1: /home/user/photon/build/distributions/photon-0.5.0/lib/commons-pool2-2.12.0.jar
jar2: /home/user/photon/build/distributions/photon-0.5.0/lib/json-20240303.jar
    at org.elasticsearch.bootstrap.JarHell.checkClass(JarHell.java:282)
    at org.elasticsearch.bootstrap.JarHell.checkJarHell(JarHell.java:192)
    at org.elasticsearch.plugins.PluginsService.loadBundles(PluginsService.java:378)
    ... 5 more

The photon-shadow-version.zip works. Should we just remove the other distribution or rename them or why are there two?

lonvia commented 2 months ago

Which jar do you try to run exactly? You should be using build/libs/photon-0.5.0.jar. There shouldn't be any files with shadow in their name anymore.

This really reminds me to update the README.

lonvia commented 2 months ago

Oh, found the distributions subdirectory. I will have to read up, who creates that.

karussell commented 2 months ago

You should be using build/libs/photon-0.5.0.jar

Ah, ok :+1: