Sunitha Kambhampati wrote: > That seems strange. I dont use Mac, but have not noticed any problems > on windows/linux.. By default, on a restart( reboot), the database is > guranteed to be in a consistent state, that is you will see only the > transactions that have been committed and not result of any uncommitted > transactions.
Yes, I'm definitely seeing the database in a consistent state, but a consistent state that doesn't contain any of the last session's data. > Maybe you have already checked this, but are you sure you > are committing all the transactions in your last sesssion ? Up until now, we haven't been using explicit transactions, but have been relying on the default autocommit setting. I have just now set the autocommit setting explicitly to true, but it's not really been long enough to determine if this had any effect (the problem is very intermittent, sometimes going days without seeing it). > that you > dont see on a reboot. Do you see any exceptions when running the > program that may cause a commit to not be issued ? Not to my knowledge, but it's something I'm explicitly logging now. > You could set derby.language.logStatementText=true and > derby.infolog.append=true and check the derby.log to look for commit > debug statements in there and what statements are executed. I've done this, and I'll see if that leads to more useful info. With only derby.infolog.append=true, I did find the following error (which may be the crux of our problem). I can't say for certain whether this conincided with a database rollback, but I suspect it may have. 2005-08-30 16:40:49.671 GMT: Booting Derby version The Apache Software Foundation - Apache Derby - 10.0.2.1 - (106978): instance c013800d-0106-0843-1b00-000075ccda01 on database directory /Users/scotty/k2db-data/k2db/pkb ------------ BEGIN ERROR MESSAGE ------------- System may be in a inconsistent state, missing file /Users/scotty/k2db- data/k2db/pkb/log/log1.dat ------------ END ERROR MESSAGE ------------- Database Class Loader started - derby.database.classpath='' 2005-08-30 16:40:53.181 GMT Thread [javawsApplicationMain,5,javawsApplicationThreadGroup] (XID = 5), (SESSIONID = 0), (DATABASE = pkb), (DRDAID = null), Committing 2005-08-30 16:40:53.182 GMT Thread [javawsApplicationMain,5,javawsApplicationThreadGroup] (XID = 5), (SESSIONID = 0), (DATABASE = pkb), (DATABASE = pkb), (DRDAID = null), Rolling back 2005-08-30 16:40:58.040 GMT Thread[AWT-EventQueue-0,6,main] (XID = 6), (SESSIONID = 1), (DATABASE = pkb), (DRDAID = null), Committing What does log1.dat store? Would the nonexistence of this file on boot cause the sort of behavior I'm seeing? > Also, are you using any other derby properties for the database apart > from the derby.storage.fileSyncTransaction:Log=true ? No, other than setting autocommit to true. Is there anything else we should be setting? Thanks for all the good questions and ideas, Scotty P.s. Sorry for the belated reply and broken thread id. My mail server is in the process of dying, and I was waiting hoping your reply would come through, but read it out of the archives instead.
