-
Artur Hefczyc wrote:
I am following the installation guide: http://docs.tigase.org/tigase-server/snapshot/User_Guide/html/#webinstall
When started the server using command:
[...]
I am getting lots of NPE and other exceptions in attached log file which look like this:
[...]
It looks to me like there is some kind of binary generation problem which causes to combine incompatible source code into distribution package.
%kobit
Not exactly. I've verified and all dependencies use correct versions, in addition we are always doing a clean build from the HEAD to avoid possible problems with caching and some such.
As web installer works more-or-less without proper configuration it generates a lot of exceptions and errors (there probably should be an additional
config-type=setup
which would skip initialization of majority of components/database) and it was happening in 7.1.0 as well:2017-02-01 12:38:17.080 [main] ConfiguratorAbstract.setProperties() SEVERE: Can't initialize user default repository: tigase.db.DBInitException: Problem initializing jdbc connection: jdbc:derby:tigase-derbydb;create=true at tigase.db.jdbc.JDBCRepository.initRepository(JDBCRepository.java:627) at tigase.db.RepositoryFactory.getUserRepository(RepositoryFactory.java:672) at tigase.conf.ConfiguratorAbstract.addUserRepo(ConfiguratorAbstract.java:888) at tigase.conf.ConfiguratorAbstract.setProperties(ConfiguratorAbstract.java:817) at tigase.conf.ConfiguratorAbstract.setup(ConfiguratorAbstract.java:519) at tigase.conf.ConfiguratorAbstract.componentAdded(ConfiguratorAbstract.java:152) at tigase.conf.Configurator.componentAdded(Configurator.java:50) at tigase.conf.Configurator.componentAdded(Configurator.java:33) at tigase.server.AbstractComponentRegistrator.addComponent(AbstractComponentRegistrator.java:116) at tigase.server.MessageRouter.addRegistrator(MessageRouter.java:138) at tigase.server.MessageRouter.setConfig(MessageRouter.java:644) at tigase.server.XMPPServer.start(XMPPServer.java:142) at tigase.server.XMPPServer.main(XMPPServer.java:112) Caused by: java.sql.SQLSyntaxErrorException: 'TIGGETDBPROPERTY' is not recognized as a function or procedure. at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source) at org.apache.derby.impl.jdbc.Util.generateCsSQLException(Unknown Source) at org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(Unknown Source) at org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(Unknown Source) at org.apache.derby.impl.jdbc.EmbedConnection.handleException(Unknown Source) at org.apache.derby.impl.jdbc.ConnectionChild.handleException(Unknown Source) at org.apache.derby.impl.jdbc.EmbedStatement.execute(Unknown Source) at org.apache.derby.impl.jdbc.EmbedStatement.executeQuery(Unknown Source) at tigase.db.jdbc.JDBCRepository.checkDBSchema(JDBCRepository.java:1060) …
Now:
- default, empty config in 7.2.0 haven't been updated to DSL format:
wojtek@atlantiscity.local ~/dev/tmps/tigase-server-dists/tigase-issue #7.2.0-SNAPSHOT-b4638 $ cat etc/init.properties config-type=--gen-config-def --admins=admin@$HOST_NAME --virt-hosts = $HOST_NAME --debug=server --comp-name-1=http --comp-class-1=tigase.http.HttpMessageReceiver http/setup/admin-credentials=admin:tigase
-
with the upgraded config there are still exceptions regarding repository which is to be expected (vide above comment);
-
ignoring the exception and taking tigase to semi-working state we run into:
2017-02-01 14:02:44.677 [main] AbstractBeanConfigurator.configure() WARNING: Can't prepare value of property 'admin-credentials' of bean 'setup': 'admin:tigase' tigase.kernel.KernelException: Unknown bean 'setup#KERNEL'.
I'm continuing working in the issue.
-
I've made a couple of fixes but it's still far from working:
-
updated the default config;
-
fixed classloader in utils (it was ignoring
tigase.db.xml.XMLRepository
because it checks for blacklisted packages and it have ".xml." as ignored package - I've whitelisted all "tigase." classes) -
make initial adjustments of tigase.db.xml.XMLRepository for new dataRepository
I'll continue tomorrow.
-
-
A few comments.
-
My conclusion about binary/version problem was based on the: java.lang.NoSuchMethodException which is usually related to incompatible APIs usage. Other exceptions: NPE and repository initialization related are expected and I understand them.
-
config-type=setup
sounds like a good idea -
I am not sure if using XMLRepository is a good idea. It has not been updated and used for quite some time. I even thought it has been removed from our code already. It seems to me that using DummyRepository instead is a better idea. But if you have already made XMLRepository working, than that's OK.
-
-
Artur Hefczyc wrote:
A few comments.
My conclusion about binary/version problem was based on the: java.lang.NoSuchMethodException which is usually related to incompatible APIs usage. Other exceptions: NPE and repository initialization related are expected and I understand them.
This was a result of lack of configuration update and the defaults handling logic not being updated as well.
config-type=setup
sounds like a good ideaAdded #4880
I am not sure if using XMLRepository is a good idea. It has not been updated and used for quite some time. I even thought it has been removed from our code already. It seems to me that using DummyRepository instead is a better idea. But if you have already made XMLRepository working, than that's OK.
I've updated XMLRepository about a year ago for the purpose of using in in the unit tests and it's quite handy for that purpose and used in many tests. What is lacking it's adjusting it to the new DataSource introduced in 7.2.0.
Andrzej was very opposed to using DummyRepository (which isn't adjusted to 7.2.0 as well)
-
I've managed to get the server to the runnable state with the default configuration; there is still work remaining to adjust components to Kernel but those will be carried out in separate tasks. Setup module will be fixed in #4896.
Type |
Bug
|
Priority |
Normal
|
Assignee | |
RedmineID |
4876
|
Version |
tigase-server-8.0.0
|
Spent time |
0
|
I am following the installation guide: http://docs.tigase.org/tigase-server/snapshot/User_Guide/html/#webinstall
When started the server using command:
I am getting lots of NPE and other exceptions in attached log file which look like this:
It looks to me like there is some kind of binary generation problem which causes to combine incompatible source code into distribution package.
tigase-console.log tigase.log.0