Skip to Content.
Sympa Menu

perfsonar-dev - r1602 - trunk/perfsonar/src/org/perfsonar/service/measurementArchive/sqlType

Subject: perfsonar development work

List archive

r1602 - trunk/perfsonar/src/org/perfsonar/service/measurementArchive/sqlType


Chronological Thread 
  • From:
  • To:
  • Subject: r1602 - trunk/perfsonar/src/org/perfsonar/service/measurementArchive/sqlType
  • Date: Wed, 6 Sep 2006 05:45:31 -0400

Author: roman
Date: 2006-09-06 05:45:30 -0400 (Wed, 06 Sep 2006)
New Revision: 1602

Modified:

trunk/perfsonar/src/org/perfsonar/service/measurementArchive/sqlType/SQLStorageManager.java

trunk/perfsonar/src/org/perfsonar/service/measurementArchive/sqlType/SQLTypeMAServiceEngine.java
Log:
Small bug removed which consisted in throwing an exception when
service.ma.sql.default_ibatis_config property was missing
but ibatisConfig parameter was present in the request (one of these two is
enough).
(This bug encountered when data with new metadata were stored in SQL MA)

Modified:
trunk/perfsonar/src/org/perfsonar/service/measurementArchive/sqlType/SQLStorageManager.java
===================================================================
---
trunk/perfsonar/src/org/perfsonar/service/measurementArchive/sqlType/SQLStorageManager.java
2006-09-06 09:12:45 UTC (rev 1601)
+++
trunk/perfsonar/src/org/perfsonar/service/measurementArchive/sqlType/SQLStorageManager.java
2006-09-06 09:45:30 UTC (rev 1602)
@@ -225,7 +225,6 @@
Key key = md.getKey();
Data data = dataSet.getDataArray()[0];

-
// ibatis action

Map ibatisParams = new HashMap();

Modified:
trunk/perfsonar/src/org/perfsonar/service/measurementArchive/sqlType/SQLTypeMAServiceEngine.java
===================================================================
---
trunk/perfsonar/src/org/perfsonar/service/measurementArchive/sqlType/SQLTypeMAServiceEngine.java
2006-09-06 09:12:45 UTC (rev 1601)
+++
trunk/perfsonar/src/org/perfsonar/service/measurementArchive/sqlType/SQLTypeMAServiceEngine.java
2006-09-06 09:45:30 UTC (rev 1602)
@@ -259,17 +259,23 @@
// metadata does not exist in xmldb

// getting default ibatis parameter from service.properties
- String ibatis_config_str =
-
configuration.getProperty("service.ma.sql.default_ibatis_config");
+ String ibatis_config_str = "";
+ try {
+ ibatis_config_str =
+
configuration.getProperty("service.ma.sql.default_ibatis_config");
+ } catch (Exception ex) {
+ ibatis_config_str = "";
+ }

Parameter ibatisConfig = null;
- if (ibatis_config_str != null ||
!ibatis_config_str.trim().equals("")) {
+ if (!ibatis_config_str.trim().equals("")) {
+
ibatisConfig = new Parameter();
ibatisConfig.setParameterName("ibatisConfig");
+
ibatisConfig.setParameterValue(ibatis_config_str);
}

-
Key k = new Key();

Random rand = new Random((new Date()).getTime());
@@ -281,6 +287,7 @@


if (ibatisConfig != null) {
+
params.getParameterMap().remove("ibatisConfig");
params.addChild(ibatisConfig);
}



  • r1602 - trunk/perfsonar/src/org/perfsonar/service/measurementArchive/sqlType, svnlog, 09/06/2006

Archive powered by MHonArc 2.6.16.

Top of Page