powered by Jive Software

Openfire 3.4.0: Bug in DB creation scripts

Second to last line in all openfire_*.sql files, which reads as follows:

INSERT INTO jiveUser (username, password, name, email, creationDate, modificationDate)

should be replaced with:

INSERT INTO jiveUser (username, plainPassword, name, email, creationDate, modificationDate)

otherwise it breaks things up.

I want to confirm this. I am not sure about other databases but at least on HSQLDB pure installation a schema file contains:

CREATE TABLE jiveUser (

username VARCHAR(64) NOT NULL,

plainPassword VARCHAR(32),

encryptedPassword VARCHAR(255),

name VARCHAR(100),

email VARCHAR(100),

creationDate VARCHAR(15) NOT NULL,

modificationDate VARCHAR(15) NOT NULL,

CONSTRAINT jiveUser_pk PRIMARY KEY (username)

);

CREATE INDEX jiveUser_cDate_idx ON jiveUser (creationDate);

But installation script trying to:

INSERT INTO jiveUser (username, password, name, email, creationDate, modificationDate)

Here is a full error log:

2007.11.01 10:48:33 org.jivesoftware.database.SchemaManager.checkSchema(SchemaManager.java:206)

java.sql.SQLException: Column not found: PASSWORD in statement

at org.hsqldb.jdbc.Util.sqlException(Unknown Source)

at org.hsqldb.jdbc.jdbcStatement.fetchResult(Unknown Source)

at org.hsqldb.jdbc.jdbcStatement.execute(Unknown Source)

at org.jivesoftware.database.SchemaManager.executeSQLScript(SchemaManager.java:348 )

at org.jivesoftware.database.SchemaManager.checkSchema(SchemaManager.java:203)

at org.jivesoftware.database.SchemaManager.checkOpenfireSchema(SchemaManager.java: 68)

at org.jivesoftware.database.DbConnectionManager.setConnectionProvider(DbConnectio nManager.java:467)

at org.jivesoftware.openfire.admin.setup.setup_002ddatasource_002dsettings_jsp._js pService(setup_002ddatasource_002dsettings_jsp.java:155)

at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:487)

at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1093)

at com.opensymphony.module.sitemesh.filter.PageFilter.parsePage(PageFilter.java:11 8)

at com.opensymphony.module.sitemesh.filter.PageFilter.doFilter(PageFilter.java:52)

at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1084)

at org.jivesoftware.util.LocaleFilter.doFilter(LocaleFilter.java:65)

at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1084)

at org.jivesoftware.util.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingF ilter.java:41)

at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1084)

at org.jivesoftware.admin.PluginFilter.doFilter(PluginFilter.java:69)

at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1084)

at org.jivesoftware.admin.AuthCheckFilter.doFilter(AuthCheckFilter.java:98)

at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1084)

at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:360)

at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)

at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181)

at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712)

at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405)

at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollect ion.java:211)

at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)

at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139)

at org.mortbay.jetty.Server.handle(Server.java:313)

at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:506)

at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.j ava:830)

at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:514)

at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211)

at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:381)

at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:396)

at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442)

So the pure new installation is broken currently. Also i should mention that there was no 13’s version of schema file in Beta2 and there was no such problem there.

Hi,

this bug will be fixed in 3.4.1 according to Gato.

reference: http://www.igniterealtime.org/community/message/159147

LG

This is good. I’ll delay the FreeBSD port until then.

Don’t worry, Nikolay, by that time they will create fresh ones. Some simple sed script could solve the problem, so there is no much reason to delay.

PS: Ups… Sorry, I haven’t seen 3.4.1 while writing this post.