powered by Jive Software

PATCH: Speed up registration page for online filtered sessions

i have attached patch, where online filtered sessions are taken from memory - not iterated trough the hole database.

also i think the the other code should be changed (optimized). currently on every request there are made numberOfRegistrations + 1 sql requests -> for my ~66000 registrations really too much…

pherhaps this code made help (from DefaultUserProvider):

pstmt = DbConnectionManager.createScrollablePreparedStatement(con, ALL_USERS);

rs = pstmt.executeQuery();

DbConnectionManager.setFetchSize(rs, startIndex + numResults);

DbConnectionManager.scrollResultSet(rs, startIndex);


altough i think, it would help very much if openfire will take use of “LIMIT x,y” in sql statements if the sql server supports it (configurable). it will make it a lot faster for a big userbase. and it shouldn’t be to hard - because it could be filtered on prepare in DbConnectionManager…

is there a reason why in gatewayRegistrations the full jid is stored ? all other tables only have the username stored.
gateway-registration.patch (10515 Bytes)