[Topic] DB migration on the client

is there any way to migrate DB on the client? I couldn't find agiletrack.conf anywhere

—Posted by slava on May 25, 2007

and I can't download server to do migration for whatever reason

—Posted by slava on May 25, 2007 at 5:13:16 AM

and, I got to download the server, export data with it, but it doesn't support SQLServer driver to import data back in. client seems to support it, but can't be used to import data?

—Posted by slava on May 25, 2007 at 5:31:37 AM

Hmm. The SQLServer libraries may not have been included with the server application. I'll have to fix that.

In the mean time, if you copy the agiletrack-sqlserver.jar and sqljdbc.jar from the client/lib directory and save them in the server/lib directory, you should be able to import into SQLServer.

In the agiletrack.conf file, "persistence-type" will be "SQLServer" and the database options are "sqlserver_user", "sqlserver_password", "sqlserver_address", "sqlserver_port", and "sqlserver_name".

As you discovered, import/export are not available in the client.

Was there a particular trick you needed to do to download the server?

—Posted by Adam Lane on May 25, 2007 at 6:37:55 AM

and, I got to download the server, export data with it, but it doesn't support SQLServer driver to import data back in. client seems to support it, but can't be used to import data?

—Posted by Guest User on May 25, 2007 at 10:04:16 AM

when I try to import to MSSQL 2005 I get this error:
The existing database will be cleared.
Import database.
484 [Thread-1] INFO : persistence.GenericFullTextIndexer – Beginning full text i
ndexer thread…
484 [main] INFO : persistence.GenericFullTextIndexer – Create new full text inde
x table.
Exception in thread "main" java.lang.reflect.InvocationTargetException

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at server.main(server.java:44)
Caused by: java.lang.NullPointerException at agiletrack.data.JSONSerializer$EncodedMap.initFromJSON(JSONSerializer
.java:77) at agiletrack.data.JSONSerializer.deserializeFromJSON(JSONSerializer.jav
a:144) at agiletrack.data.JSONSerializer.deserializeJSONObject(JSONSerializer.j
ava:187) at agiletrack.server.app.ServerApplication.importDatabase(ServerApplicat
ion.java:413) at agiletrack.server.app.ServerApplication.main(ServerApplication.java:2
80) ... 5 more
—Posted by slava on May 25, 2007 at 10:10:59 AM

when I create a blank DB in SQL 2005 and just try to connect AgileTrack client to it I get:

2781 [Thread-2] INFO : persistence.GenericFullTextIndexer – Beginning full text indexer thread…
4547 [AgileTrack – Bridge Polling] INFO : controller.TrackerServerBridge – Begin background cache management thread…
5031 [SplashThread] ERROR: server.ServerApplication – Problem initializing client application.
java.lang.ClassCastException: agiletrack.data.record.Product cannot be cast to agiletrack.data.record.State

at agiletrack.data.TrackerEnhancedLoaderDefault.getStateList(TrackerEnhancedLoaderDefault.java:591) at agiletrack.client.controller.TrackerSession.getStateList(TrackerSession.java:432) at agiletrack.client.ClientApplication$1$1.initialization(ClientApplication.java:216) at agiletrack.swing.JSplashScreen$2.run(JSplashScreen.java:73) at java.lang.Thread.run(Unknown Source)
—Posted by slava on May 25, 2007 at 10:12:27 AM

about trick to download the server. for whatever reason I was getting logged out when I clicked on the download link. I guess it was browser cache problem. I clicked on log in again, logged in and was redirected to the download.

thing you can do is when I'm required to log-in, say so and put a link to log-in page.

—Posted by slava on May 25, 2007 at 9:03:57 PM

I wasn't able to reproduce the first problem exactly, but I think I've solved it. It had to do with some key fields getting used before being initialized. I've updated the 1.1.1 server release with a fix. If you download the server.zip again, it should have the fix included. The SQLServer drivers are also included now.

The second problem was probably due to a cache problem caused by changing data sources. If you delete default.dat from the client lib directory, it would probably fix that problem.

—Posted by Adam Lane on May 29, 2007 at 4:21:06 PM

import works now (although takes a while). I can't log-in to the new database. I guess something to do with hash?

—Posted by slava on May 30, 2007 at 8:34:47 AM

import works now (although takes a while). I can't log-in to the new database. I guess something to do with hash?

—Posted by slava on May 30, 2007 at 9:07:24 AM

getting this error:
10953 [SplashThread] ERROR: server.ServerApplication – Problem initializing client application.
java.lang.NullPointerException

at agiletrack.server.security.TrackerDataSecurityDefault.hasPermission(TrackerDataSecurityDefault.java:97) at agiletrack.server.security.TrackerDataSecurityDefault.canExecuteRecordSearch(TrackerDataSecurityDefault.java:570) at agiletrack.server.TrackerModel.findRecords(TrackerModel.java:858) at agiletrack.server.controller.TrackerLocalAccess.search(TrackerLocalAccess.java:94) at agiletrack.client.controller.TrackerServerBridge.findInternalRecords(TrackerServerBridge.java:361) at agiletrack.client.controller.TrackerServerBridge.findRecords(TrackerServerBridge.java:197) at agiletrack.data.TrackerEnhancedLoaderDefault.findRecords(TrackerEnhancedLoaderDefault.java:145) at agiletrack.data.TrackerEnhancedLoaderDefault.getUserList(TrackerEnhancedLoaderDefault.java:619) at agiletrack.client.controller.TrackerSession.getUserList(TrackerSession.java:452) at agiletrack.client.ClientApplication$1$1.initialization(ClientApplication.java:204) at agiletrack.swing.JSplashScreen$2.run(JSplashScreen.java:73) at java.lang.Thread.run(Unknown Source)
—Posted by slava on May 30, 2007 at 9:10:46 AM

the problem appeared because Role IDs changed on migration, but they weren't updated in the user database.

also, it seems that all issue IDs got reset?

—Posted by slava on May 30, 2007 at 9:17:12 AM

I'm glad the migration sort of worked. The renumbering is due to the merge migration capability that is there, but it really shouldn't happen if the clear-data option is set. If you're willing to do the migration again, I'll make a fix that preserves all of the IDs and put it out tonight.

I think I know why it takes a while and I'll fix that in the future as well. It has to do with the full text indexing, but it's fixable.

—Posted by Adam Lane on May 30, 2007 at 11:37:37 AM

I can do it again if you can speed it up. It took 2 hours to do it… don't really have that much time to fool around.

btw, with your updates, do I need to export again? or just re-import?

—Posted by slava on May 30, 2007 at 8:55:29 PM

I've fixed the speed problem. I was able to import about 10000 records in just a couple minutes. You won't need to export again, just re-import. Just download the 1.1.1 server zip again and it should take care of things.

—Posted by Adam Lane on May 31, 2007 at 6:27:22 AM

I tried to upgrade again. it worked faster. Issue IDs are still reversed (1 becomes a 1000 and old 1000 becomes 1), or maybe they're just random, but I see issues I added right before migration to have the lowest ID.

problem with invalid roles is still present.

—Posted by slava on May 31, 2007 at 1:04:06 PM

btw. it seems that you fixed the GUI problem. I haven't had a freeze in new version yet. thanks and good job.

—Posted by slava on Jun 2, 2007 at 8:10:02 PM

I'm about to put out a small release. The import function has been modified a bit. If clear persistence is true, no renumbering will occur. If clear persistence is false, it will merge the incoming with the existing records and won't duplicate roles, users, or states.

—Posted by Adam Lane on Jul 23, 2007 at 9:59:51 AM


You may post a reply to this topic, but you must be logged in. If you already have an account, you may login now. If you need to create an account, you may also register now.