You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Suresh Thalamati (JIRA)" <de...@db.apache.org> on 2006/01/13 20:46:20 UTC
[jira] Commented: (DERBY-810) intermittent diff for
store/RecoveryAfterBackup.java test
[ http://issues.apache.org/jira/browse/DERBY-810?page=comments#action_12362682 ]
Suresh Thalamati commented on DERBY-810:
----------------------------------------
Difference in the output seems to be a new line. My guess is System.out and System.err (output of the printStackTrace() ) output to the file are getting intermingled.
Related code in RecoveryAfterBackup.java:
// Shut down database
Properties shutdownAttrs = new Properties();
shutdownAttrs.setProperty("shutdownDatabase", "shutdown");
System.out.println("Shutting down database ...");
try {
DataSource ds = TestUtil.getDataSource(shutdownAttrs);
ds.getConnection();
} catch (Throwable ith) {
ith.printStackTrace();
}
// Start up with rollforward-recovery
System.out.println("Starting restore with roll-forward recovery..");
Oyestin: I did not notice this when I reviewed the patch for Derby-298. Any particular reason for printing stack trace on shutdown ? Normally I check for the shutdown SQLState and not print the stack trace if the shutdown is successful. I think to avoid timing issues with tests , it is better to print the stack traces to System.out .
output in the temp file:
Count: 2 Sum: 1
Inserting records ...
Shutting down database ...
SQL Exception: Derby system shutdown.Starting restore with roll-forward recovery..
at org.apache.derby.impl.jdbc.Util.newEmbedSQLException(Util.java:80)
at org.apache.derby.impl.jdbc.Util.newEmbedSQLException(Util.java:97)
at org.apache.derby.impl.jdbc.Util.generateCsSQLException(Util.java:161)
at org.apache.derby.jdbc.InternalDriver.connect(InternalDriver.java:182)
at org.apache.derby.jdbc.EmbeddedDataSource.getConnection(EmbeddedDataSource.java:478)
at org.apache.derby.jdbc.EmbeddedDataSource.getConnection(EmbeddedDataSource.java:422)
at org.apache.derbyTesting.functionTests.tests.store.RecoveryAfterBackup.main(RecoveryAfterBackup.java:85)
Verifying database ...
Count: 256 Sum: 32640
> intermittent diff for store/RecoveryAfterBackup.java test
> ---------------------------------------------------------
>
> Key: DERBY-810
> URL: http://issues.apache.org/jira/browse/DERBY-810
> Project: Derby
> Type: Test
> Components: Store
> Versions: 10.2.0.0
> Environment: Sun jdk 1.5
> Reporter: Kathey Marsden
> Fix For: 10.2.0.0
>
> I saw this diff for test running at 2006-01-11 00:45:23 PST. The test seemed to run fine the next night.It would appear that this is some sort of intermittent test output problem. The test was just checked in on 2006-01-09.
> store/RecoveryAfterBackup.java. on jdk15
> *** Start: RecoveryAfterBackup jdk1.5.0_02 storeall:storerecovery 2006-01-11 00:45:23 ***
> 4 del
> < SQL Exception: Derby system shutdown.
> 5 del
> < Starting restore with roll-forward recovery..
> 5a4
> > SQL Exception: Derby system shutdown.Starting restore with roll-forward recovery..
> Test Failed.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[PATCH] Re: [jira] Commented: (DERBY-810) intermittent diff for
store/RecoveryAfterBackup.java test
Posted by Øystein Grøvlen <Oy...@Sun.COM>.
>>>>> "ST(" == Suresh Thalamati (JIRA) <de...@db.apache.org> writes:
ST(> [ http://issues.apache.org/jira/browse/DERBY-810?page=comments#action_12362682 ]
ST(> Suresh Thalamati commented on DERBY-810:
ST(> ----------------------------------------
ST(> Difference in the output seems to be a new line. My guess is
ST(> System.out and System.err (output of the printStackTrace() )
ST(> output to the file are getting intermingled.
I have attached a patch to JIRA that should solve this problem.
Please, review and commit it.
--
Øystein