Project

General

Profile

Server start error after added MUC component

Song Hu
Added over 1 year ago

Hi, I am new to Tigase.

I recently downloaded tigase-server and tigase-muc latest source code(version 7.2.0) from Tigase git, installed mvn and openJdk and eclipse groovy plugins and so, now I am able to compile and package tigase-server and tigase-muc without change any source codes.

Now the situation is: If I don't load any comps where starting tigase server by using ./script/tigase.sh start etc/tigase.conf command, the tigase server can start successfully, and all core functions works fine. But if I add muc component in the init.properties, the server will getting error when starting. Seems the MUC component is not correctly compiled/packaged!!

The server error logs is as below:

Loading component: sess-man :: componentInfo{Title=Tigase XMPP Server, Version=7.2.0-SNAPSHOT-b4942/9d3d9d4f (2017-08-07/02:05:27), Class=tigase.server.xmppsession.SessionManager}

Loading component: c2s :: componentInfo{Title=Tigase XMPP Server, Version=7.2.0-SNAPSHOT-b4942/9d3d9d4f (2017-08-07/02:05:27), Class=tigase.server.xmppclient.ClientConnectionManager}

Loading component: ws2s :: componentInfo{Title=Tigase XMPP Server, Version=7.2.0-SNAPSHOT-b4942/9d3d9d4f (2017-08-07/02:05:27), Class=tigase.server.websocket.WebSocketClientConnectionManager}

Loading component: monitor :: componentInfo{Title=Tigase XMPP Server, Version=7.2.0-SNAPSHOT-b4942/9d3d9d4f (2017-08-07/02:05:27), Class=tigase.monitor.MonitorComponent}

Loading component: eventbus :: componentInfo{Title=Tigase XMPP Server, Version=7.2.0-SNAPSHOT-b4942/9d3d9d4f (2017-08-07/02:05:27), Class=tigase.eventbus.component.EventBusComponent}

Loading component: s2s :: componentInfo{Title=Tigase XMPP Server, Version=7.2.0-SNAPSHOT-b4942/9d3d9d4f (2017-08-07/02:05:27), Class=tigase.server.xmppserver.S2SConnectionManager}

2017-08-07 15:28:53.023 [main] Kernel.getInstance() SEVERE: Exception getting instance

java.lang.RuntimeException: java.lang.NullPointerException

at tigase.muc.repository.inmemory.InMemoryMucRepository.initialize(InMemoryMucRepository.java:293)

at tigase.kernel.core.Kernel.initBean(Kernel.java:157)

at tigase.kernel.core.Kernel.injectDependencies(Kernel.java:582)

at tigase.kernel.core.Kernel.initBean(Kernel.java:152)

at tigase.kernel.core.Kernel.injectDependencies(Kernel.java:582)

at tigase.kernel.core.Kernel.initBean(Kernel.java:152)

at tigase.kernel.core.Kernel.injectDependencies(Kernel.java:582)

at tigase.kernel.core.Kernel.injectDependency(Kernel.java:770)

at tigase.kernel.core.Kernel$DelayedDependenciesInjection.inject(Kernel.java:1373)

at tigase.kernel.core.Kernel.finishDependecyDelayedInjection(Kernel.java:1035)

at tigase.kernel.core.Kernel.initBean(Kernel.java:148)

at tigase.kernel.core.Kernel.injectDependencies(Kernel.java:582)

at tigase.kernel.core.Kernel.initBean(Kernel.java:152)

at tigase.kernel.core.Kernel.getInstance(Kernel.java:388)

at tigase.server.Bootstrap.start(Bootstrap.java:148)

at tigase.server.XMPPServer.start(XMPPServer.java:136)

at tigase.server.XMPPServer.main(XMPPServer.java:117)

Caused by: java.lang.NullPointerException

at tigase.muc.repository.JDBCMucDAO.getRoomsJIDList(JDBCMucDAO.java:191)

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 tigase.stats.StatisticsInvocationHandler.invoke(StatisticsInvocationHandler.java:80)

at com.sun.proxy.$Proxy29.getRoomsJIDList(Unknown Source)

at tigase.muc.repository.MucDAOMDBean.lambda$getRoomsJIDList$0(MucDAOMDBean.java:93)

at java.util.stream.ReferencePipeline$7$1.accept(ReferencePipeline.java:267)

at java.util.concurrent.ConcurrentHashMap$ValueSpliterator.forEachRemaining(ConcurrentHashMap.java:3566)

at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481)

at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471)

at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:708)

at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)

at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:499)

at tigase.muc.repository.MucDAOMDBean.getRoomsJIDList(MucDAOMDBean.java:99)

at tigase.muc.repository.inmemory.InMemoryMucRepository.initialize(InMemoryMucRepository.java:286)

at tigase.kernel.core.Kernel.initBean(Kernel.java:157)

at tigase.kernel.core.Kernel.injectDependencies(Kernel.java:582)

at tigase.kernel.core.Kernel.initBean(Kernel.java:152)

at tigase.kernel.core.Kernel.injectDependencies(Kernel.java:582)

at tigase.kernel.core.Kernel.initBean(Kernel.java:152)

at tigase.kernel.core.Kernel.injectDependencies(Kernel.java:582)

at tigase.kernel.core.Kernel.injectDependency(Kernel.java:770)

at tigase.kernel.core.Kernel$DelayedDependenciesInjection.inject(Kernel.java:1373)

at tigase.kernel.core.Kernel.finishDependecyDelayedInjection(Kernel.java:1035)

at tigase.kernel.core.Kernel.initBean(Kernel.java:148)

at tigase.kernel.core.Kernel.injectDependencies(Kernel.java:582)

at tigase.kernel.core.Kernel.initBean(Kernel.java:152)

at tigase.kernel.core.Kernel.getInstance(Kernel.java:388)

at tigase.server.Bootstrap.start(Bootstrap.java:148)

at tigase.server.XMPPServer.start(XMPPServer.java:136)

at tigase.server.XMPPServer.main(XMPPServer.java:117)

=============================================================================

ERROR! Terminating the server process.

Problem initializing the server: tigase.kernel.KernelException: java.lang.RuntimeException: java.lang.NullPointerException

Please fix the problem and start the server again.

=============================================================================

Please kindly suggestion how to compile/package muc component by using muc source code with maven command, so I can have MUC component in my tigase server. Thanks a lot.


Replies (2)

Added by Andrzej Wójcik IoT 1 CloudTigaseTeam over 1 year ago

Have you loaded MUC component schema to the database which you are using?

Some components, ie. MUC have separate schema and it needs to be loaded to database as without it components will not work.

Added by Song Hu over 1 year ago

Great!! Perfectly solved my problem. Thanks a lot.

    (1-2/2)