[jboss-cvs] JBossCache/tests-50/functional/org/jboss/cache/pojo ...
Ben Wang
bwang at jboss.com
Wed Jan 3 04:38:39 EST 2007
User: bwang
Date: 07/01/03 04:38:39
Modified: tests-50/functional/org/jboss/cache/pojo LocalTxTest.java
Log:
upd
Revision Changes Path
1.7 +60 -46 JBossCache/tests-50/functional/org/jboss/cache/pojo/LocalTxTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: LocalTxTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/LocalTxTest.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -b -r1.6 -r1.7
--- LocalTxTest.java 3 Jan 2007 07:35:43 -0000 1.6
+++ LocalTxTest.java 3 Jan 2007 09:38:39 -0000 1.7
@@ -194,6 +194,7 @@
t2_ex = e;
}
}
+ t2_ex = ex;
ex.printStackTrace();
}
}
@@ -266,6 +267,8 @@
}
catch (Exception ex)
{
+ if(tx != null)
+ {
try
{
tx.rollback();
@@ -275,6 +278,9 @@
t2_ex = e;
}
}
+ t2_ex = ex;
+ ex.printStackTrace();
+ }
}
};
@@ -310,9 +316,12 @@
{
try
{
- for(int i=0; i< 10; i++)
+ for(int i=0; i< 100; i++)
{
- Person p = createPerson("/p1/test7", "p6", 50);
+ String id = "/p1/test7";
+ Person p = createPerson(id, "p6", 50);
+ cache.detach(id);
+ p = createPerson(id, "p6", 51);
List<String> lang = new ArrayList<String>();
tx = getTransaction();
tx.begin();
@@ -330,7 +339,11 @@
}
catch (RollbackException rollback)
{
- ;
+ rollback.printStackTrace();
+ }
+ catch (PojoCacheException pe)
+ {
+ pe.printStackTrace();
}
catch (Exception ex)
{
@@ -347,9 +360,12 @@
{
try
{
- for(int i=0; i< 10; i++)
+ for(int i=0; i< 100; i++)
{
- Person p = createPerson("/p2/test8", "p6", 50);
+ String id = "/p1/test8";
+ Person p = createPerson(id, "p6", 50);
+ cache.detach(id);
+ p = createPerson(id, "p6", 51);
List<String> lang = new ArrayList<String>();
tx = getTransaction();
tx.begin();
@@ -367,18 +383,16 @@
}
catch (RollbackException rollback)
{
- ;
+ rollback.printStackTrace();
}
- catch (Exception ex)
- {
- try
+ catch (PojoCacheException pe)
{
- tx.rollback();
- } catch (SystemException e)
- {
- e.printStackTrace();
- t2_ex = e;
+ pe.printStackTrace();
}
+ catch (Exception ex)
+ {
+ t2_ex = ex;
+ ex.printStackTrace();
}
}
};
More information about the jboss-cvs-commits
mailing list