git://source.jalview.org
/
jabaws.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Stat collection and display done
[jabaws.git]
/
webservices
/
compbio
/
stat
/
collector
/
StatDB.java
diff --git
a/webservices/compbio/stat/collector/StatDB.java
b/webservices/compbio/stat/collector/StatDB.java
index
56ce9c1
..
c2dd29a
100644
(file)
--- a/
webservices/compbio/stat/collector/StatDB.java
+++ b/
webservices/compbio/stat/collector/StatDB.java
@@
-105,7
+105,7
@@
public class StatDB {
+ "isCollected SMALLINT NOT NULL, "
\r
+ "isClusterJob SMALLINT NOT NULL)";
\r
// We create a table...
\r
+ "isCollected SMALLINT NOT NULL, "
\r
+ "isClusterJob SMALLINT NOT NULL)";
\r
// We create a table...
\r
- System.out.println(create);
\r
+ log.debug(create);
\r
s.execute(create);
\r
s.close();
\r
conn.close();
\r
s.execute(create);
\r
s.close();
\r
conn.close();
\r
@@
-153,6
+153,7
@@
public class StatDB {
pstm.executeUpdate();
\r
}
\r
conn.commit();
\r
pstm.executeUpdate();
\r
}
\r
conn.commit();
\r
+ conn.setAutoCommit(true);
\r
pstm.close();
\r
}
\r
\r
pstm.close();
\r
}
\r
\r
@@
-310,8
+311,7
@@
public class StatDB {
conn.close();
\r
}
\r
} catch (SQLException e) {
\r
conn.close();
\r
}
\r
} catch (SQLException e) {
\r
- System.err.println("Database commit failed with "
\r
- + e.getLocalizedMessage());
\r
+ log.warn("Database commit failed with " + e.getLocalizedMessage());
\r
}
\r
boolean gotSQLExc = false;
\r
try {
\r
}
\r
boolean gotSQLExc = false;
\r
try {
\r
@@
-322,9
+322,9
@@
public class StatDB {
}
\r
}
\r
if (!gotSQLExc) {
\r
}
\r
}
\r
if (!gotSQLExc) {
\r
- System.err.println("Database did not shut down normally");
\r
+ log.warn("Database did not shut down normally");
\r
} else {
\r
} else {
\r
- System.out.println("Database shut down normally");
\r
+ log.info("Database shut down normally");
\r
}
\r
}
\r
public static void main(String[] args) throws SQLException {
\r
}
\r
}
\r
public static void main(String[] args) throws SQLException {
\r