db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kmars...@apache.org
Subject svn commit: r348593 [2/2] - in /db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests: master/ master/j9_foundation/ tests/i18n/ tests/lang/ tests/store/ tests/storetests/ tests/tools/ util/
Date Wed, 23 Nov 2005 23:43:24 GMT
Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/TestDurabilityProperty.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/TestDurabilityProperty.java?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/TestDurabilityProperty.java (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/TestDurabilityProperty.java Wed Nov 23 15:42:53 2005
@@ -23,9 +23,11 @@
 import java.sql.Connection;
 import java.sql.Statement;
 import java.sql.PreparedStatement;
-import java.sql.DriverManager;
 import java.sql.SQLException;
 import java.io.*;
+import org.apache.derbyTesting.functionTests.util.TestUtil;
+import java.util.Properties;
+
 
 /**
  * This program tests the system when the derby.system.durability property is
@@ -122,7 +124,7 @@
 
         try {
             conn.close();
-            DriverManager.getConnection("jdbc:derby:;shutdown=true");
+			TestUtil.shutdownUsingDataSource("");
         } catch (SQLException sqle) {
             if ("XJ015".equals(sqle.getSQLState())) {
             }// ok database shutdown

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/TestDurabilityProperty_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/TestDurabilityProperty_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/TestDurabilityProperty_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/TestDurabilityProperty_app.properties Wed Nov 23 15:42:53 2005
@@ -1,5 +1,2 @@
-#Exclude for J2ME/Foundation - test requires java.sql.DriverManager
-runwithfoundation=false
-
 usedefaults=true
 

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore.sql
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore.sql?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore.sql (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore.sql Wed Nov 23 15:42:53 2005
@@ -7,22 +7,22 @@
 select cast (dv(x) as dec(5,2)) from x;
 ----take a backup.
 call SYSCS_UTIL.SYSCS_BACKUP_DATABASE('extinout/mybackup');
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 
 ---restore a databases
-connect 'jdbc:derby:wombat;restoreFrom=extinout/mybackup/wombat';
+connect 'wombat;restoreFrom=extinout/mybackup/wombat';
 select cast (dv(x) as dec(5,2)) from x;
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 
 ---create a new database from backup.
-connect 'jdbc:derby:wombatnew;createFrom=extinout/mybackup/wombat';
+connect 'wombatnew;createFrom=extinout/mybackup/wombat';
 select cast (dv(x) as dec(5,2)) from x;
-connect 'jdbc:derby:wombatnew;shutdown=true';
+connect 'wombatnew;shutdown=true';
 disconnect;
 
-connect 'jdbc:derby:wombat';
+connect 'wombat';
 select cast (dv(x) as dec(5,2)) from x;
 call SYSCS_UTIL.SYSCS_BACKUP_DATABASE_AND_ENABLE_LOG_ARCHIVE_MODE('extinout/mybackup', 1);
 insert into x values (1,1),(10,1),(20,1);
@@ -30,13 +30,13 @@
 insert into x values (1,1),(10,1),(20,1);
 insert into x values (1,1),(10,1),(20,1);
 select cast (dv(x) as dec(5,2)) from x;
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 
 ---perform a rollforward recovery
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 select * from x;
 select cast (dv(x) as dec(5,2)) from x;
 insert into x values (1,1),(10,1),(20,1);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore1.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore1.java?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore1.java (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore1.java Wed Nov 23 15:42:53 2005
@@ -27,13 +27,14 @@
 
 import java.sql.CallableStatement;
 import java.sql.Connection;
-import java.sql.DriverManager;
 import java.sql.SQLException;
 import java.sql.PreparedStatement;
 import java.sql.ResultSet;
 import java.sql.Statement;
 import org.apache.derby.tools.ij;
 import org.apache.derby.tools.JDBCDisplayUtil;
+import org.apache.derbyTesting.functionTests.util.TestUtil;
+import java.util.Properties;
 
 /**
  * Test of backup restore through java program JDBC calls.
@@ -121,7 +122,7 @@
 		//shutdown the database ..
 		try{
 			//shutdown 
-			Connection conn = DriverManager.getConnection("jdbc:derby:wombat;shutdown=true");
+			TestUtil.shutdownUsingDataSource("wombat");
 		}catch(SQLException se){
 				if (se.getSQLState() != null && se.getSQLState().equals("08006"))
 					System.out.println("database shutdown properly");
@@ -134,8 +135,10 @@
 		System.out.println("testing rollforward recovery");
 		try{
 			//perform rollforward recovery and do some inserts again
-			Connection conn = DriverManager.getConnection(
-														  "jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat");
+			Properties prop = new Properties();
+			prop.setProperty("databaseName","wombat");
+			prop.setProperty("connectionAttributes", "rollForwardRecoveryFrom=extinout/mybackup/wombat");
+			Connection conn = TestUtil.getDataSourceConnection(prop);
 			//run consistenct checker
 			Statement stmt = conn.createStatement();
 			stmt.execute("VALUES (ConsistencyChecker())");
@@ -149,7 +152,7 @@
 
             conn.commit();
 			conn.close();
-			conn = DriverManager.getConnection("jdbc:derby:wombat;shutdown=true");
+			TestUtil.shutdownUsingDataSource("wombat");
 		}
         catch( SQLException se)
         {
@@ -167,8 +170,10 @@
 		RandomAccessFile rfs = null;
 		boolean alreadyShutdown = false;
 		try{
-			Connection conn = DriverManager.getConnection("jdbc:derby:wombat");
-					
+			Properties prop = new Properties();
+			prop.setProperty("databaseName","wombat");
+			Connection conn = TestUtil.getDataSourceConnection(prop);
+								
 			//just open to a file in existing backup, so that rename will fail on
 			//next backup
 			rfs = 
@@ -181,8 +186,7 @@
             backupStmt.execute();
             backupStmt.close();
 			conn.close();
-
-			conn = DriverManager.getConnection("jdbc:derby:wombat;shutdown=true");
+			TestUtil.shutdownUsingDataSource("wombat");
 		}catch(SQLException se)
 		{
 			if (se.getSQLState() != null && se.getSQLState().equals("XSRS4"))
@@ -207,7 +211,7 @@
 		{
 			try{
 				//shutdown 
-				Connection conn = DriverManager.getConnection("jdbc:derby:wombat;shutdown=true");
+				TestUtil.shutdownUsingDataSource("wombat");
 			}catch(SQLException se){
 				if (se.getSQLState() != null && se.getSQLState().equals("08006"))
 					System.out.println("database shutdown properly");
@@ -223,13 +227,18 @@
 			//close the earlier opened file in backup dir
 			if(rfs != null )
 				rfs.close();
-			Connection conn = DriverManager.getConnection("jdbc:derby:wombat;restoreFrom=extinout/mybackup/wombat");
+			
+			Properties prop = new Properties();
+			prop.setProperty("databaseName","wombat");
+			prop.setProperty("connectionAttributes","restoreFrom=extinout/mybackup/wombat");
+			Connection conn = TestUtil.getDataSourceConnection(prop);
+			
 			//run consistenct checker
 			Statement stmt = conn.createStatement();
 			stmt.execute("VALUES (ConsistencyChecker())");
 			conn.close();
 			//shutdown the backup db;
-			conn = DriverManager.getConnection("jdbc:derby:wombat;shutdown=true");
+			TestUtil.shutdownUsingDataSource("wombat");
 		}catch(SQLException se)
 		{
 			if (se.getSQLState() != null && se.getSQLState().equals("08006"))
@@ -242,8 +251,10 @@
 
 		//now take a backup again , just to make all is well in the system.
 		try{
-			Connection conn = DriverManager.getConnection("jdbc:derby:wombat");
-
+			Properties prop = new Properties();
+			prop.setProperty("databaseName","wombat");
+			Connection conn = TestUtil.getDataSourceConnection(prop);
+			
             CallableStatement backupStmt = conn.prepareCall(
                 "CALL SYSCS_UTIL.SYSCS_BACKUP_DATABASE(?)");
             backupStmt.setString(1, "extinout/mybackup");
@@ -253,7 +264,7 @@
 			Statement stmt = conn.createStatement();
 			stmt.execute("VALUES (ConsistencyChecker())");
 			conn.close();
-			conn = DriverManager.getConnection("jdbc:derby:wombat;shutdown=true");
+			TestUtil.shutdownUsingDataSource("wombat");
 		}catch(SQLException se)
 		{
 			if (se.getSQLState() != null && se.getSQLState().equals("08006"))

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore1_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore1_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore1_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore1_app.properties Wed Nov 23 15:42:53 2005
@@ -14,8 +14,5 @@
 usedefaults=true
 useextdirs=true
 
-#Exclude for J2ME/Foundation - test requires java.sql.DriverManager
-runwithfoundation=false
-
 #exclude with SecurityManager DERBY-709
 noSecurityManager=true

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/backupRestore_app.properties Wed Nov 23 15:42:53 2005
@@ -2,8 +2,5 @@
 usedefaults=true
 useextdirs=true
 
-#Exclude for J2ME/Foundation - test requires java.sql.Driver
-runwithfoundation=false
-
 #exclude with SecurityManager DERBY-709
 noSecurityManager=true

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/connectDisconnect_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/connectDisconnect_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/connectDisconnect_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/connectDisconnect_app.properties Wed Nov 23 15:42:53 2005
@@ -1,5 +1,2 @@
-#Exclude for J2ME/Foundation - test requires java.sql.DriverManager
-runwithfoundation=false
-
 usedefaults=true
 

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/databaseProperties_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/databaseProperties_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/databaseProperties_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/databaseProperties_app.properties Wed Nov 23 15:42:53 2005
@@ -1,6 +1,3 @@
-#Exclude for J2ME/Foundation - test requires java.sql.DriverManager
-runwithfoundation=false
-
 usedefaults=true
 
 

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/logDevice_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/logDevice_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/logDevice_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/logDevice_app.properties Wed Nov 23 15:42:53 2005
@@ -20,9 +20,6 @@
 ij.dataSource.createDatabase=create
 ij.dataSource.connectionAttributes=logDevice=extinout/wierdlog
 
-#Exclude for J2ME/Foundation - test requires java.sql.DriverManager
-runwithfoundation=false
-
 #exclude with SecurityManager DERBY-709
 noSecurityManager=true
 

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/removeStubs.sql
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/removeStubs.sql?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/removeStubs.sql (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/removeStubs.sql Wed Nov 23 15:42:53 2005
@@ -4,10 +4,10 @@
 autocommit off ;
 drop table t1 ;
 commit ;
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect all;
 
-connect 'jdbc:derby:wombat';
+connect 'wombat';
 autocommit on;
 create table t1(a int ) ;
 drop table t1 ;
@@ -18,13 +18,13 @@
 create table t1(a int ) ;
 drop table t1 ;
 CALL SYSCS_UTIL.SYSCS_CHECKPOINT_DATABASE();
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect all;
-connect 'jdbc:derby:wombat';
+connect 'wombat';
 create table t2( a int ) ;
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect all;
-connect 'jdbc:derby:wombat';
+connect 'wombat';
 drop table t2 ;
 CALL SYSCS_UTIL.SYSCS_CHECKPOINT_DATABASE();
 CALL SYSCS_UTIL.SYSCS_CHECKPOINT_DATABASE();

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/removeStubs_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/removeStubs_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/removeStubs_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/removeStubs_app.properties Wed Nov 23 15:42:53 2005
@@ -1,5 +1,2 @@
-#Exclude for J2ME/Foundation - test requires java.sql.Driver
-runwithfoundation=false
-
 usedefaults=true
 

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardBackup.sql
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardBackup.sql?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardBackup.sql (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardBackup.sql Wed Nov 23 15:42:53 2005
@@ -41,10 +41,10 @@
 insert into t1 values(4) ;
 insert into t1 values(5);
 insert into t1 values(6);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 --performa rollforward recovery
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 select * from t1 ;
 insert into t1 values(7);
 insert into t1 values(8);
@@ -55,10 +55,10 @@
 insert into t1 values(10);
 insert into t1 values(11);
 insert into t1 values(12);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 --perform complete version restore
-connect 'jdbc:derby:wombat;restoreFrom=extinout/mybackup/wombat';
+connect 'wombat;restoreFrom=extinout/mybackup/wombat';
 select * from t1 ;
 insert into t1 values(10);
 insert into t1 values(11);
@@ -68,43 +68,43 @@
 insert into t1 values(15);
 call SYSCS_UTIL.SYSCS_BACKUP_DATABASE_AND_ENABLE_LOG_ARCHIVE_MODE(
     'extinout/mybackup', 1);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 --create a new database using wombat db backup copy with a different database name
-connect 'jdbc:derby:wombat1;createFrom=extinout/mybackup/wombat';
+connect 'wombat1;createFrom=extinout/mybackup/wombat';
 select * from t1;
 insert into t1 values(16);
 insert into t1 values(17);
 insert into t1 values(18);
 call SYSCS_UTIL.SYSCS_BACKUP_DATABASE_AND_ENABLE_LOG_ARCHIVE_MODE(
     'extinout/mybackup', 1);
-connect 'jdbc:derby:wombat1;shutdown=true';
+connect 'wombat1;shutdown=true';
 disconnect;
 ---BACKUP AND RESTORE USING LOGDEVICE.
-connect 'jdbc:derby:crwombat;createFrom=extinout/mybackup/wombat;logDevice=extinout/crwombatlog';
+connect 'crwombat;createFrom=extinout/mybackup/wombat;logDevice=extinout/crwombatlog';
 values SUBSTR(SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice'), LOCATE('crwombatlog',SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice')),11);
 select * from t1;
 insert into t1 values(19);
 insert into t1 values(20);
 insert into t1 values(21);
-connect 'jdbc:derby:crwombat;shutdown=true';
+connect 'crwombat;shutdown=true';
 disconnect;
 --do a plain boot , we should have the log device specified earlier.
-connect 'jdbc:derby:crwombat';
+connect 'crwombat';
 values SUBSTR(SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice'), LOCATE('crwombatlog',SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice')),11);
 
 select * from t1;
 insert into t1 values(22);
 insert into t1 values(23);
 insert into t1 values(24);
-connect 'jdbc:derby:crwombat;shutdown=true';
+connect 'crwombat;shutdown=true';
 disconnect;
 ---check the error case of log device only existing when
 -- we try to do createFrom .
 --following connection shoul fail.
-connect 'jdbc:derby:erwombat;createFrom=extinout/mybackup/wombat;logDevice=extinout/crwombatlog';
+connect 'erwombat;createFrom=extinout/mybackup/wombat;logDevice=extinout/crwombatlog';
 
-connect 'jdbc:derby:wombat;restoreFrom=extinout/mybackup/wombat;logDevice=extinout/wombatlog';
+connect 'wombat;restoreFrom=extinout/mybackup/wombat;logDevice=extinout/wombatlog';
 values SUBSTR(SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice'), LOCATE('wombatlog',SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice')),9);
 
 select * from t1 ;
@@ -113,20 +113,20 @@
 insert into t1 values(21);
 call SYSCS_UTIL.SYSCS_BACKUP_DATABASE_AND_ENABLE_LOG_ARCHIVE_MODE(
     'extinout/mybackup', 1);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 --restore again from backup case to make sure
 --backups are getting the log device property.	
-connect 'jdbc:derby:wombat;restoreFrom=extinout/mybackup/wombat';
+connect 'wombat;restoreFrom=extinout/mybackup/wombat';
 values SUBSTR(SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice'), LOCATE('wombatlog',SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice')),9);
 select * from t1;
 insert into t1 values(22);
 insert into t1 values(23);
 insert into t1 values(24);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 --do a vannila boot and see the device to make sure the log device is still intact.
-connect 'jdbc:derby:wombat';
+connect 'wombat';
 values SUBSTR(SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice'), LOCATE('wombatlog',SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice')),9);
 
 select * from t1;
@@ -135,36 +135,36 @@
 insert into t1 values(26);
 insert into t1 values(27);
 rollback;
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 
 --performa rollforward recovery with logDevice specified at backup
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 values SUBSTR(SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice'), LOCATE('wombatlog',SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice')),9);
 select * from t1 ;
 insert into t1 values(25);
 insert into t1 values(26);
 insert into t1 values(27);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 
 --perform a rollforward recovery with log device is moved
 --to some other place than what it was when backup was taken.
 --move the log to different dir name.
-connect 'jdbc:derby:dummycondb;createFrom=extinout/mybackup/wombat;logDevice=extinout/wombatlog1';
+connect 'dummycondb;createFrom=extinout/mybackup/wombat;logDevice=extinout/wombatlog1';
 call RENAME_FILE(null,'extinout/wombatlog','extinout/wombatlogmoved');
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat;logDevice=extinout/wombatlogmoved';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat;logDevice=extinout/wombatlogmoved';
 values SUBSTR(SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice'), LOCATE('wombatlogmoved',SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice')),14);
 
 select * from t1 ;
 insert into t1 values(30);
 insert into t1 values(31);
 insert into t1 values(32);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 --do a plain boot and verify the log device.
-connect 'jdbc:derby:wombat';
+connect 'wombat';
 values SUBSTR(SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice'), LOCATE('wombatlogmoved',SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice')),14);
 select * from t1 ;
 insert into t1 values(33);
@@ -173,32 +173,32 @@
 --take a fresh backup again with moved log device.
 call SYSCS_UTIL.SYSCS_BACKUP_DATABASE_AND_ENABLE_LOG_ARCHIVE_MODE(
     'extinout/mybackup', 1);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 --restore and check the results;
-connect 'jdbc:derby:wombat;restoreFrom=extinout/mybackup/wombat';
+connect 'wombat;restoreFrom=extinout/mybackup/wombat';
 values SUBSTR(SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice'), LOCATE('wombatlogmoved',SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice')),14);
 select * from t1;
 insert into t1 values(36);
 insert into t1 values(37);
 insert into t1 values(38);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 --simulate OS type copy and then boot(Commented because it does not work in nightlies)
---connect 'jdbc:derby:dummycondb';
+--connect 'dummycondb';
 --call RENAME_FILE('rollForwardBackup', 'wombat', 'wombat.old');
 --call RENAME_FILE(null, 'extinout/mybackup/wombat', 'rollForwardBackup/wombat');
 ---disconnect;
----connect 'jdbc:derby:wombat';
+---connect 'wombat';
 --Following SHOULD SHOW NULL value.
 --values SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice');
 --select * from t1;
 --call SYSCS_UTIL.SYSCS_BACKUP_DATABASE_AND_ENABLE_LOG_ARCHIVE_MODE(
 --     'extinout/mybackup', 1);
---connect 'jdbc:derby:wombat;shutdown=true';
+--connect 'wombat;shutdown=true';
 --disconnect;
 ---createFrom without logDevice specified on URL should have null value.
-connect 'jdbc:derby:tempwombat;createFrom=extinout/mybackup/wombat';
+connect 'tempwombat;createFrom=extinout/mybackup/wombat';
 values SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice');
 select * from t1;
 insert into t1 values(39);
@@ -206,17 +206,17 @@
 insert into t1 values(41);
 call SYSCS_UTIL.SYSCS_BACKUP_DATABASE_AND_ENABLE_LOG_ARCHIVE_MODE(
     'extinout/mybackup', 1);
-connect 'jdbc:derby:tempwombat;shutdown=true';
+connect 'tempwombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;restoreFrom=extinout/mybackup/tempwombat';
+connect 'wombat;restoreFrom=extinout/mybackup/tempwombat';
 values SYSCS_UTIL.SYSCS_GET_DATABASE_PROPERTY('logDevice');
 call SYSCS_UTIL.SYSCS_BACKUP_DATABASE_AND_ENABLE_LOG_ARCHIVE_MODE(
     'extinout/mybackup', 1);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 
 ---Using plain backup mechanism rstore/recreate db using  restoreFrom/createFrom
-connect 'jdbc:derby:wombat';
+connect 'wombat';
 call SYSCS_UTIL.SYSCS_DISABLE_LOG_ARCHIVE_MODE(1);
 select * from t1;
 insert into t1 values(42);
@@ -228,66 +228,66 @@
 insert into t1 values(45);
 insert into t1 values(46);
 insert into t1 values(47);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;restoreFrom=extinout/mybackup/wombat';
+connect 'wombat;restoreFrom=extinout/mybackup/wombat';
 select * from t1;
 insert into t1 values(45);
 insert into t1 values(46);
 insert into t1 values(47);
 call SYSCS_UTIL.SYSCS_BACKUP_DATABASE('extinout/mybackup');
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombatnew;createFrom=extinout/mybackup/wombat';
+connect 'wombatnew;createFrom=extinout/mybackup/wombat';
 select * from t1;
 insert into t1 values(48);
 insert into t1 values(49);
 insert into t1 values(50);
-connect 'jdbc:derby:wombatnew;shutdown=true';
+connect 'wombatnew;shutdown=true';
 disconnect;
 --enable the log archive mode again.
-connect 'jdbc:derby:wombat';
+connect 'wombat';
 call SYSCS_UTIL.SYSCS_BACKUP_DATABASE_AND_ENABLE_LOG_ARCHIVE_MODE(
     'extinout/mybackup', 1);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 
 --NEGATIVE TEST with  RESTORE FLAGS
 -- with createFrom option should give erro on existing database
-connect 'jdbc:derby:wombat;createFrom=extinout/mybackup/wombat';
+connect 'wombat;createFrom=extinout/mybackup/wombat';
 -- specify conflictint attributes; it should fail.
-connect 'jdbc:derby:wombat;create=true;createFrom=extinout/mybackup/wombat';
-connect 'jdbc:derby:wombat;create=true;rollForwardRecoveryFrom=extinout/mybackup/wombat';
-connect 'jdbc:derby:wombat;create=true;restoreFrom=extinout/mybackup/wombat';
-connect 'jdbc:derby:wombat;restoreFrom=extinout/mybackup/wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
-connect 'jdbc:derby:wombat;createFrom=extinout/mybackup/wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;create=true;createFrom=extinout/mybackup/wombat';
+connect 'wombat;create=true;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;create=true;restoreFrom=extinout/mybackup/wombat';
+connect 'wombat;restoreFrom=extinout/mybackup/wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;createFrom=extinout/mybackup/wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 -- With wrong back up path name it shoud fail.
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=nobackup/wombat';
-connect 'jdbc:derby:wombat;restoreFrom=nobackup/wombat';
-connect 'jdbc:derby:wombat2;createFrom=nobackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=nobackup/wombat';
+connect 'wombat;restoreFrom=nobackup/wombat';
+connect 'wombat2;createFrom=nobackup/wombat';
 --Simulate missing files by renaming some files in backup(like a corrupted backup and check 
 --whether we get proper error messages
 --Get a connection because it is required to make any calls in ij 
-connect 'jdbc:derby:wombat2;restoreFrom=extinout/mybackup/wombat';
+connect 'wombat2;restoreFrom=extinout/mybackup/wombat';
 call RENAME_FILE('extinout/mybackup/wombat/','service.properties','service.properties.old');
-connect 'jdbc:derby:wombat;restoreFrom=extinout/mybackup/wombat';
+connect 'wombat;restoreFrom=extinout/mybackup/wombat';
 call RENAME_FILE('extinout/mybackup/wombat/','service.properties.old','service.properties');
 call RENAME_FILE('extinout/mybackup/wombat/','log','log.old');
-connect 'jdbc:derby:wombat;restoreFrom=extinout/mybackup/wombat';
+connect 'wombat;restoreFrom=extinout/mybackup/wombat';
 call RENAME_FILE('extinout/mybackup/wombat/','log.old','log');
 call RENAME_FILE('extinout/mybackup/wombat/','seg0','data.old');
-connect 'jdbc:derby:wombat;restoreFrom=extinout/mybackup/wombat';
+connect 'wombat;restoreFrom=extinout/mybackup/wombat';
 call RENAME_FILE('extinout/mybackup/wombat/','data.old','seg0');
 --try error cases with createFrom;if root created is not getting cleaned up,
 --next createFrom call will fail with DBLOCATION/wombat exist error.
 call RENAME_FILE('extinout/mybackup/wombat/','service.properties','service.properties.old');
-connect 'jdbc:derby:wombat;createFrom=extinout/mybackup/wombat';
+connect 'wombat;createFrom=extinout/mybackup/wombat';
 call RENAME_FILE('extinout/mybackup/wombat/','service.properties.old','service.properties');
 call RENAME_FILE('extinout/mybackup/wombat/','log','log.old');
-connect 'jdbc:derby:wombat;createFrom=extinout/mybackup/wombat';
+connect 'wombat;createFrom=extinout/mybackup/wombat';
 call RENAME_FILE('extinout/mybackup/wombat/','log.old','log');
 call RENAME_FILE('extinout/mybackup/wombat/','seg0','data.old');
-connect 'jdbc:derby:wombat;createFrom=extinout/mybackup/wombat';
+connect 'wombat;createFrom=extinout/mybackup/wombat';
 call RENAME_FILE('extinout/mybackup/wombat/','data.old','seg0');
 
 drop procedure RENAME_FILE;

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardBackup_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardBackup_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardBackup_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardBackup_app.properties Wed Nov 23 15:42:53 2005
@@ -13,8 +13,5 @@
 useextdirs=true
 usedefaults=true
 
-#Exclude for J2ME/Foundation - test requires java.sql.DriverManager
-runwithfoundation=false
-
 #exclude with SecurityManager DERBY-709
 noSecurityManager=true

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardRecovery.sql
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardRecovery.sql?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardRecovery.sql (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardRecovery.sql Wed Nov 23 15:42:53 2005
@@ -7,9 +7,9 @@
 insert into t1 values(2) ;
 insert into t1 values(3 ) ;
 drop table t1;
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat';
+connect 'wombat';
 --checkpoint to make sure that 
 --the stub is dropped and we use the 
 --the same container id which we dropped earlier
@@ -20,10 +20,10 @@
 insert into t1 values(5);
 insert into t1 values(6);
 select * from t1;
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
 --performa rollforward recovery
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 select * from t1 ;
 --drop the above tables and create
 --again tables with foreign key references and
@@ -42,9 +42,9 @@
 insert into t2 values(3);
 alter table t2 add constraint c1 foreign key (b)
                              references t1(a);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 insert into t2 values(4);
 insert into t2 values(5);
 select * from t1;
@@ -80,9 +80,9 @@
 --alter table t4 add column c2 int not null;
 --alter table t3 add column c3 int not null unique;
 
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 select * from t1;
 select * from t2;
 select * from t3;
@@ -97,17 +97,17 @@
 alter table t4 add constraint fk1 foreign key (c1) references t3(c1);
 --unlogged add unique constraint
 alter table t4 add constraint uk2 unique(c1);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 --following insert should throw duplicate error.
 insert into t4 values(101);
 insert into t3 (c1) values(101);
 --folowing should throw foreign key violations error.
 insert into t4 values(9999);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 select * from t1;
 select * from t2;
 select c1 from t3;
@@ -125,9 +125,9 @@
 delete from t4;
 delete from t3;
 rollback;
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 select * from t1;
 select * from t2;
 select * from t3;
@@ -142,9 +142,9 @@
 alter table t5 add constraint uconst UNIQUE(c4);
 insert into t5 values ( 1 , 2, 3 , 'one'), 
 (11 , 22, 33, 'eleven'), (111, 222, 333, 'one hundred eleven');
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 select * from t5 ;
 --check if constraits are intact.
 --following insert  should throw error because they violate constraints;
@@ -154,9 +154,9 @@
 insert into t5 values ( 1111 , 2222, 3333 , 'four ones ..');
 
 select * from t5;
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 select * from t5;
 --- Have to check long varchar/binary  recovery stuff.
 -- create a table with 5 rows, with 4K pageSize,
@@ -175,9 +175,9 @@
 insert into testing values (PADSTRING('10000000',2024), PADSTRING('20000000',1024), PADSTRING('30000000',1024),  PADSTRING('40000000',2048),  PADSTRING('50000000',300));
 insert into testing values (PADSTRING('100000000',2024),PADSTRING('200000000',1024), PADSTRING('300000000',1024), PADSTRING('400000000',2048), PADSTRING('500000000',300));
 
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 
 -- select the whole row, or individual columns.
 -- 9 rows should be returned from each of the following selects
@@ -194,9 +194,9 @@
 insert into testing (a, b, c) values (PADSTRING('a',2024), PADSTRING('b',1024), PADSTRING('c',1024));
 insert into testing (a, b, c, d) values (PADSTRING('a',2024), PADSTRING('b',1024), PADSTRING('c',1024), PADSTRING('d',2048));
 insert into testing (a, b, c, d, e) values (PADSTRING('a',2024), PADSTRING('b',1024), PADSTRING('c',1024), PADSTRING('d',2048), PADSTRING('e',300));
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 -- select some partial rows.
 -- should select 14 rows
 select * from testing;
@@ -237,9 +237,9 @@
 -- update all columns for 2 rows
 update testing set a = PADSTRING('aaa',2024), b = PADSTRING('bbb',1024), c = PADSTRING('ccc',1024), d = PADSTRING('ddd',2048), e = PADSTRING('eee',300)
 	where d = PADSTRING('d',2048);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 
 -- following select should return 0 rows
 select * from testing where d = PADSTRING('d',2048);
@@ -277,9 +277,9 @@
 insert into testing values (1, PADSTRING('fill1',2500), PADSTRING('fill2',2500), 10, PADSTRING('fill3',2500), PADSTRING('fill4',2500), 100, PADSTRING('fill5',2400), PADSTRING('fill6',2400), 1000);
 insert into testing values (2, PADSTRING('fill1',2500), PADSTRING('fill2',2500), 20, PADSTRING('fill3',2500), PADSTRING('fill4',2500), 200, PADSTRING('fill5',2400), PADSTRING('fill6',2400), 2000);
 
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 
 select * from testing;
 select key2 from testing;
@@ -311,9 +311,9 @@
 insert into testing values (PADSTRING('a b c d e f g h i j',8096));
 insert into testing values (PADSTRING('11 22 33 44 55 66 77',8096));
 insert into testing values (PADSTRING('aa bb cc dd ee ff gg',8096));
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 -- should return 4 rows
 select a from testing;
 -- drop the table
@@ -326,9 +326,9 @@
 insert into testing values (3, PADSTRING('11 22 33 44 55 66 77',32384));
 insert into testing values (4, PADSTRING('aa bb cc dd ee ff gg',32384));
 
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 
 -- should return 4 rows
 select * from testing;
@@ -346,9 +346,9 @@
 insert into testing values (PADSTRING('11 22 33 44 55 66 77',32384), 3);
 insert into testing values (PADSTRING('aa bb cc dd ee ff gg',32384), 4);
 
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 -- should return 4 rows
 select * from testing;
 select a from testing;
@@ -364,9 +364,9 @@
 insert into testing values (1, PADSTRING('a b c d e f g h i j',32384), 2);
 insert into testing values (2, PADSTRING('11 22 33 44 55 66 77',32384), 3);
 insert into testing values (4, PADSTRING('aa bb cc dd ee ff gg',32384), 4);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 -- should return 4 rows
 select * from testing;
 select a from testing;
@@ -383,9 +383,9 @@
 update testing set a = PADSTRING('update four times',32384);
 update testing set a = PADSTRING('update five times',32384);
 
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 -- select should return 4 rows
 select a from testing;
 -- drop the table
@@ -397,9 +397,9 @@
 insert into testing values (PADSTRING('a b c d e f g h i j',32384), 2, PADSTRING('a b c d e f g h i j',32084));
 insert into testing values (PADSTRING('11 22 33 44 55 66 77',32384), 3, PADSTRING('11 22 33 44 55 66 77',32084));
 insert into testing values (PADSTRING('aa bb cc dd ee ff gg',32384), 4, PADSTRING('aa bb cc dd ee ff gg',32084));
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 -- should return 4 rows
 select * from testing;
 select a from testing;
@@ -422,9 +422,9 @@
 update testing set c = PADSTRING('update 7',32084);
 update testing set c = PADSTRING('update 8',32084);
 update testing set c = PADSTRING('update 9',32084);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 -- select should return 4 rows
 select * from testing;
 -- drop the table
@@ -440,9 +440,9 @@
 insert into testing values (5, PADSTRING('a b c d e f g h i j',64768),  6, PADSTRING('aa bb cc dd ee ff gg',32384), 7);
 insert into testing values (6, PADSTRING('11 22 33 44 55 66 77',64768), 7, PADSTRING('aa bb cc dd ee ff gg',32384), 8);
 insert into testing values (7, PADSTRING('aa bb cc dd ee ff gg',64768), 8, PADSTRING('aa bb cc dd ee ff gg',32384), 9);
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 -- select shoudl return 8 rows
 select * from testing;
 select a from testing;
@@ -460,9 +460,9 @@
 update testing set b = PADSTRING('update 8',64768);
 update testing set b = PADSTRING('update 9',64768);
 
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 -- select should return 8 rows
 select b from testing;
 select a, b, e from testing;
@@ -482,9 +482,9 @@
 insert into testing values (PADSTRING('a a a a a a a a a a',64768), PADSTRING('b b b b b b b b b b',32384), PADSTRING('c c c c c c c c c c',64768), PADSTRING('d d d d d d d d d d',32384), PADSTRING('e e e e e e e e',64768));
 insert into testing values (PADSTRING('a a a a a a a a a a',64768), PADSTRING('b b b b b b b b b b',32384), PADSTRING('c c c c c c c c c c',64768), PADSTRING('d d d d d d d d d d',32384), PADSTRING('e e e e e e e e',64768));
 
-connect 'jdbc:derby:wombat;shutdown=true';
+connect 'wombat;shutdown=true';
 disconnect;
-connect 'jdbc:derby:wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
+connect 'wombat;rollForwardRecoveryFrom=extinout/mybackup/wombat';
 
 -- select should return 10 rows
 select * from testing;

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardRecovery_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardRecovery_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardRecovery_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/rollForwardRecovery_app.properties Wed Nov 23 15:42:53 2005
@@ -13,8 +13,5 @@
 useextdirs=true
 usedefaults=true
 
-#Exclude for J2ME/Foundation - test requires java.sql.Driver
-runwithfoundation=false
-
 #exclude with SecurityManager DERBY-709
 noSecurityManager=true

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/derby94_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/derby94_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/derby94_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/derby94_app.properties Wed Nov 23 15:42:53 2005
@@ -1,5 +1,2 @@
-#Exclude for J2ME/Foundation - test requires java.sql.DriverManager
-runwithfoundation=false
-
 usedefaults=true
 

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/st_1_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/st_1_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/st_1_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/st_1_app.properties Wed Nov 23 15:42:53 2005
@@ -1,6 +1,3 @@
-#Exclude for J2ME/Foundation - test requires java.sql.DriverManager
-runwithfoundation=false
-
 usedefaults=true
 
 #exclude with SecurityManager for now

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/st_b5772_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/st_b5772_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/st_b5772_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/st_b5772_app.properties Wed Nov 23 15:42:53 2005
@@ -1,5 +1,2 @@
-#Exclude for J2ME/Foundation - test requires java.sql.DriverManager
-runwithfoundation=false
-
 usedefaults=true
 

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/st_schema_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/st_schema_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/st_schema_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/storetests/st_schema_app.properties Wed Nov 23 15:42:53 2005
@@ -2,11 +2,12 @@
 # storetests creates the database and wants autocommit mode
 #
 #
-database=jdbc:derby:wombat;create=true
+ij.database=jdbc:derby:wombat;create=true
 derby.infolog.append=true
 ij.showNoConnectionsAtStart=true
 ij.showNoCountForSelect=true
 ij.defaultResourcePackage=/org/apache/derbyTesting/functionTests/tests/storetests/
 
-#Exclude for J2ME/Foundation - test requires java.sql.Driver
-runwithfoundation=false
\ No newline at end of file
+# DataSource properties, only used if ij.dataSource is set
+ij.dataSource.databaseName=wombat
+ij.dataSource.createDatabase=create

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/iepnegativetests.sql
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/iepnegativetests.sql?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/iepnegativetests.sql (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/iepnegativetests.sql Wed Nov 23 15:42:53 2005
@@ -210,8 +210,8 @@
 insert into parent values (1) , (2) , (3) , (4) ;
 call SYSCS_UTIL.SYSCS_EXPORT_QUERY('select * from parent where a < 3' , 'extinout/parent.del' , 
                                  null, null, null) ;
-connect 'jdbc:derby:wombat' as c1;
-connect 'jdbc:derby:wombat' as c2;
+connect 'wombat' as c1;
+connect 'wombat' as c2;
 set connection c1;
 autocommit off;
 lock table iep.parent in share mode;

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/iepnegativetests_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/iepnegativetests_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/iepnegativetests_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/iepnegativetests_app.properties Wed Nov 23 15:42:53 2005
@@ -1,8 +1,7 @@
+ij.protocol=jdbc:derby:
+
 usedefaults=true
 useextdirs=true
-
-#Exclude for J2ME/Foundation - test requires java.math.BigDecimal
-runwithfoundation=false
 
 # disable security manager for now - need investigating
 noSecurityManager=true

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/ij2_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/ij2_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/ij2_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/ij2_app.properties Wed Nov 23 15:42:53 2005
@@ -4,10 +4,11 @@
 #
 #
 ij.protocol=jdbc:derby:
-database=wombat;create=true
+ij.database=wombat;create=true
 
 ij.showNoConnectionsAtStart=true
 ij.showNoCountForSelect=true
 
-#Exclude for J2ME/Foundation - test requires java.sql.Driver
-runwithfoundation=false
\ No newline at end of file
+# DataSource properties, only used if ij.dataSource is set
+ij.dataSource.databaseName=wombat
+ij.dataSource.createDatabase=create
\ No newline at end of file

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/ij4_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/ij4_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/ij4_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/ij4_app.properties Wed Nov 23 15:42:53 2005
@@ -3,5 +3,5 @@
 ij.showNoConnectionsAtStart=true
 ij.showNoCountForSelect=true
 
-#Exclude for J2ME/Foundation - test requires java.sql.Driver
+#Exclude for J2ME/Foundation - ij test with no default driver or database
 runwithfoundation=false

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/ij_app.properties
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/ij_app.properties?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/ij_app.properties (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/tools/ij_app.properties Wed Nov 23 15:42:53 2005
@@ -6,5 +6,5 @@
 ij.showNoConnectionsAtStart=true
 ij.showNoCountForSelect=true
 
-#Exclude for J2ME/Foundation - test requires java.sql.Driver
+#Exclude for J2ME/Foundation - test is specific to ij and tests bad/good urls
 runwithfoundation=false

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/util/TestUtil.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/util/TestUtil.java?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/util/TestUtil.java (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/util/TestUtil.java Wed Nov 23 15:42:53 2005
@@ -28,15 +28,33 @@
 import java.util.Hashtable;
 import java.util.Locale;
 import java.util.Properties;
+
+import javax.sql.DataSource;
+
 import org.apache.derby.iapi.reference.JDBC30Translation;
 
 
+
+
 /**
 	Utility methods for tests, in order to bring some consistency to test
 	output and handle testing framework differences
 
 */
 public class TestUtil {
+	
+	//Used for JSR169
+	public static boolean HAVE_DRIVER_CLASS;
+	static{
+		try{
+			Class.forName("java.sql.Driver");
+			HAVE_DRIVER_CLASS = true;
+		}
+		catch(ClassNotFoundException e){
+			//Used for JSR169
+			HAVE_DRIVER_CLASS = false;
+		}
+	}
 
 	public static final int UNKNOWN_FRAMEWORK = -1;
 
@@ -79,6 +97,7 @@
 	private static String XA_DATASOURCE_STRING = "XA";
 	private static String CONNECTION_POOL_DATASOURCE_STRING = "ConnectionPool";
 	private static String REGULAR_DATASOURCE_STRING = "";
+	private static String JSR169_DATASOURCE_STRING = "Simple";
 	
 	// Methods for making framework dependent decisions in tests.
 
@@ -239,8 +258,12 @@
 	 */
 	public static javax.sql.DataSource getDataSource(Properties attrs)
 	{
+		String classname;
+		if(HAVE_DRIVER_CLASS)
+			classname = getDataSourcePrefix() + REGULAR_DATASOURCE_STRING + "DataSource";
+		else
+			classname = getDataSourcePrefix() + JSR169_DATASOURCE_STRING + "DataSource";
 		
-		String classname = getDataSourcePrefix() + REGULAR_DATASOURCE_STRING + "DataSource";
 		return (javax.sql.DataSource) getDataSourceWithReflection(classname, attrs);
 	}
 
@@ -636,9 +659,29 @@
 		}
 
 	}
-
-
+	
+	public static Connection getDataSourceConnection (Properties prop) throws SQLException {
+		DataSource ds = TestUtil.getDataSource(prop);
+		try {
+			Connection conn = ds.getConnection();
+			return conn;
+		}
+		catch (SQLException e) {
+			throw e;
+		}
+	}
+	
+	public static void shutdownUsingDataSource (String dbName) throws SQLException {
+		Properties prop = new Properties();
+		prop.setProperty("databaseName", dbName );
+		prop.setProperty("shutdownDatabase", "shutdown" );
+		DataSource ds = TestUtil.getDataSource(prop);
+		try {
+			Connection conn = ds.getConnection();
+		}
+		catch (SQLException e) {
+			throw e;
+		}
+	}
 }
-
-
 

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/util/testRoutines.sql
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/util/testRoutines.sql?rev=348593&r1=348592&r2=348593&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/util/testRoutines.sql (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/util/testRoutines.sql Wed Nov 23 15:42:53 2005
@@ -1,3 +1,4 @@
-CREATE PROCEDURE TESTROUTINE.INSTALL_ROUTINES() MODIFIES SQL DATA EXTERNAL NAME 'org.apache.derbyTesting.functionTests.util.TestRoutines.installRoutines' language java parameter style java;  
-CALL TESTROUTINE.INSTALL_ROUTINES();
-DROP PROCEDURE TESTROUTINE.INSTALL_ROUTINES;
+-- Changed to create individual procedures so that this will work with JSR169. 
+-- Direct call to 'installRoutines' uses nested connection
+CREATE PROCEDURE TESTROUTINE.SET_SYSTEM_PROPERTY(IN PROPERTY_KEY VARCHAR(32000), IN PROPERTY_VALUE VARCHAR(32000)) NO SQL EXTERNAL NAME 'org.apache.derbyTesting.functionTests.util.TestRoutines.setSystemProperty' language java parameter style java;
+CREATE PROCEDURE TESTROUTINE.SLEEP(IN SLEEP_TIME_MS BIGINT) NO SQL EXTERNAL NAME 'org.apache.derbyTesting.functionTests.util.TestRoutines.sleep' language java parameter style java;



Mime
View raw message