Update from develop and cannot start...
-
Hi all, I did a pull this evening to build and update my jar, to check the latest awesomeness, but now I cannot start my poor server. I have backups and all, so there is no catastrophe here. But I would like to know what the problem is.
The bottom of the log says:
SLF4J: Class path contains multiple SLF4J bindings. SLF4J: Found binding in [jar:file:/home/njb/Desktop/mycontroller/lib/mycontrolle r-dist-standalone-0.0.3.Final-SNAPSHOT-single.jar!/org/slf4j/impl/StaticLoggerBi nder.class] SLF4J: Found binding in [jar:file:/home/njb/Desktop/mycontroller/lib/original-my controller-dist-standalone-0.0.3.Final-SNAPSHOT-single.jar!/org/slf4j/impl/Stati cLoggerBinder.class] SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation. SLF4J: Actual binding is of type [ch.qos.logback.classic.util.ContextSelectorSta ticBinder] 2017-04-15 23:01:18,514 INFO [main] [org.mycontroller.standalone.db.DataBaseUtil s:116] Checking migration... 2017-04-15 23:01:19,151 INFO [main] [org.mycontroller.standalone.db.DataBaseUtil s:167] Application information: [Version:0.0.3.Final-SNAPSHOT, Database(type:H2 database embedded, version:1.4.194 (2017-03-10), schema version:1.03.06 - 2017 M ar 03), Built on:2017-04-15T22:48:40+0200, Git commit:356da1e110375bdf3080cb835f aa5734830cd6f9:development] 2017-04-15 23:01:19,311 INFO [Thread-6] [org.mycontroller.standalone.message.Raw MessageQueue:54] Cleared offline messages[0] from the queue. 2017-04-15 23:01:19,339 ERROR [main] [org.mycontroller.standalone.StartApp:99] U nable to start application, refer error log, java.lang.RuntimeException: Could not instantiate class at org.mapdb.SerializerPojo.deserializeUnknownHeader(SerializerPojo.java:483) at org.mapdb.SerializerBase.deserialize3(SerializerBase.java:1216) at org.mapdb.SerializerBase.deserialize(SerializerBase.java:1132) at org.mapdb.SerializerBase.deserialize(SerializerBase.java:867) at org.mapdb.SerializerPojo.deserialize(SerializerPojo.java:701) at org.mapdb.HTreeMap$2.deserialize(HTreeMap.java:135) at org.mapdb.HTreeMap$2.deserialize(HTreeMap.java:121) at org.mapdb.Store.deserialize(Store.java:297) at org.mapdb.StoreDirect.get2(StoreDirect.java:486) at org.mapdb.StoreWAL.get2(StoreWAL.java:336) at org.mapdb.StoreWAL.get(StoreWAL.java:320) at org.mapdb.Caches$HashTable.get(Caches.java:246) at org.mapdb.HTreeMap$HashIterator.findNextLinkedNodeRecur(HTreeMap.java:1089) at org.mapdb.HTreeMap$HashIterator.findNextLinkedNode(HTreeMap.java:1054) at org.mapdb.HTreeMap$HashIterator.<init>(HTreeMap.java:978) at org.mapdb.HTreeMap$KeyIterator.<init>(HTreeMap.java:1116) at org.mapdb.HTreeMap$KeySet.iterator(HTreeMap.java:818) at io.moquette.spi.persistence.MapDBSessionsStore.listAllSubscriptions(MapDBSessionsStore.java:105) at io.moquette.spi.impl.subscriptions.SubscriptionsStore.init(SubscriptionsStore.java:108) at io.moquette.spi.impl.ProtocolProcessorBootstrapper.init(ProtocolProcessorBootstrapper.java:107) at io.moquette.server.Server.startServer(Server.java:160) at io.moquette.server.Server.startServer(Server.java:143) at io.moquette.server.Server.startServer(Server.java:132) at org.mycontroller.standalone.mqttbroker.MoquetteMqttBroker.start(MoquetteMqttBroker.java:50) at org.mycontroller.standalone.StartApp.startServices(StartApp.java:285) at org.mycontroller.standalone.StartApp.startMycontroller(StartApp.java:111) at org.mycontroller.standalone.StartApp.main(StartApp.java:97) Caused by: java.lang.IllegalArgumentException: Can not set final io.moquette.parser.proto.messages.AbstractMessage$QOSType field io.moquette.spi.impl.subscriptions.Subscription.requestedQos to io.moquette.proto.messages.AbstractMessage$QOSType at sun.reflect.UnsafeFieldAccessorImpl.throwSetIllegalArgumentException(UnsafeFieldAccessorImpl.java:167) at sun.reflect.UnsafeFieldAccessorImpl.throwSetIllegalArgumentException(UnsafeFieldAccessorImpl.java:171) at sun.reflect.UnsafeQualifiedObjectFieldAccessorImpl.set(UnsafeQualifiedObjectFieldAccessorImpl.java:83) at java.lang.reflect.Field.set(Field.java:764) at org.mapdb.SerializerPojo.setFieldValue(SerializerPojo.java:346) at org.mapdb.SerializerPojo.deserializeUnknownHeader(SerializerPojo.java:478) ... 26 common frames omitted Exception in thread "MyController.org Shutdown-Hook" java.lang.NullPointerException at Acme.Serve.Serve.stopBackground(Serve.java:684) at org.jboss.resteasy.plugins.server.tjws.TJWSServletServer.stop(TJWSServletServer.java:184) at org.mycontroller.standalone.StartApp.stopHTTPWebServer(StartApp.java:225) at org.mycontroller.standalone.StartApp.stopServices(StartApp.java:309) at org.mycontroller.standalone.AppShutdownHook$1.run(AppShutdownHook.java:34)
-
You can visit this. https://github.com/mycontroller-org/mycontroller/issues/362
However, we have up to date SNAPSHOT version available at http://forum.mycontroller.org/topic/58/download-snapshot-build
-
Hi , I am actually building from source, and just copying the jar file. It has worked many times with the below script. Maybe you can have a look and decide if that is a stupid approach, considering data migrations, configuration file changes etc....??
# goto home directory cd # stop the server and wait for it ./Desktop/mycontroller/bin/stop.sh sleep 10 # take a backup just in case cp -a mycontroller mycontroller_backup # assuming repository present and pulling latest source cd Desktop/clonse/mycontroller git pull # build it from source mvn package # copy jar file and start server cp -r dist/target/*single.jar /home/$USER/Desktop/mycontroller/lib cd ./Desktop/mycontroller/bin/start.sh
-
- Do not copy
original-my controller-dist-standalone-0.0.3.Final-SNAPSHOT-single.jar
- copy only
mycontroller-dist-standalone-0.0.3.Final-SNAPSHOT-single.jar
, delete all other jar files on/home/njb/Desktop/mycontroller/lib/
- Do not copy