perfsonar-dev - r1787 - in branches/yi-udel/perfsonar: schema/example-instances/sonar/LS/test src/org/perfsonar/client/testHarness src/org/perfsonar/service/lookupService/xmlType
Subject: perfsonar development work
List archive
r1787 - in branches/yi-udel/perfsonar: schema/example-instances/sonar/LS/test src/org/perfsonar/client/testHarness src/org/perfsonar/service/lookupService/xmlType
Chronological Thread
- From:
- To:
- Subject: r1787 - in branches/yi-udel/perfsonar: schema/example-instances/sonar/LS/test src/org/perfsonar/client/testHarness src/org/perfsonar/service/lookupService/xmlType
- Date: Wed, 29 Nov 2006 17:25:18 -0500
Author: yi
Date: 2006-11-29 17:25:17 -0500 (Wed, 29 Nov 2006)
New Revision: 1787
Added:
branches/yi-udel/perfsonar/schema/example-instances/sonar/LS/test/LSQueryRequest.xml
Removed:
branches/yi-udel/perfsonar/schema/example-instances/sonar/LS/test/LSQueryRequest.xml
Modified:
branches/yi-udel/perfsonar/src/org/perfsonar/client/testHarness/LSTestClientScenario.java
branches/yi-udel/perfsonar/src/org/perfsonar/service/lookupService/xmlType/LSLookupAction.java
Log:
I've made a performance test, and realized that in BDB, the OR ("|")
operation at collection level
is approx. much slower than doing 2 or more separate queries, probably the
same thing holds in eXist,
so consider separate the single query in LSQueryRequest
Deleted:
branches/yi-udel/perfsonar/schema/example-instances/sonar/LS/test/LSQueryRequest.xml
Added:
branches/yi-udel/perfsonar/schema/example-instances/sonar/LS/test/LSQueryRequest.xml
Modified:
branches/yi-udel/perfsonar/src/org/perfsonar/client/testHarness/LSTestClientScenario.java
===================================================================
---
branches/yi-udel/perfsonar/src/org/perfsonar/client/testHarness/LSTestClientScenario.java
2006-11-29 20:07:40 UTC (rev 1786)
+++
branches/yi-udel/perfsonar/src/org/perfsonar/client/testHarness/LSTestClientScenario.java
2006-11-29 22:25:17 UTC (rev 1787)
@@ -15,7 +15,7 @@
{
static Vector<String> servers = new Vector<String> ();
- static final int N = 32;
+ static final int N = 128;
static String tmpFile =
"schema/example-instances/sonar/LS/test/tmp.xml";
public static void main(String[] args)
@@ -188,7 +188,7 @@
static void genQueryRequest (String file, String server)
{
- String hostName = "*."+ server + ".edu";
+ String hostName = server + ".edu";
try
{
@@ -208,7 +208,7 @@
fw.write(" let $collection :=
(collection (\"LSStore.dbxml\") | collection (\"LSCache.dbxml\"))\n");
fw.write(" for $m in
$collection/nmwg:metadata,\n");
fw.write(" $d in
$collection/nmwg:data\n");
- fw.write(" where
$m/@id=$d/@metadataIdRef and matches ($d//nmwgt:hostName/text(), \"." +
hostName + "\")\n");
+ fw.write(" where
$m/@id=$d/@metadataIdRef and contains ($d//nmwgt:hostName, \"." + hostName +
"\")\n");
fw.write(" return $m\n");
fw.write(" </xquery:subject>\n");
fw.write("
<nmwg:eventType>service.lookup.xquery</nmwg:eventType>\n");
@@ -307,8 +307,8 @@
static String generateString ()
{
- // string length [2, 6]
- int min = 2;
+ // string length [4, 10]
+ int min = 4;
int max = 10;
int stringLen = min + (int)(Math.random() * (max - min));
Modified:
branches/yi-udel/perfsonar/src/org/perfsonar/service/lookupService/xmlType/LSLookupAction.java
===================================================================
---
branches/yi-udel/perfsonar/src/org/perfsonar/service/lookupService/xmlType/LSLookupAction.java
2006-11-29 20:07:40 UTC (rev 1786)
+++
branches/yi-udel/perfsonar/src/org/perfsonar/service/lookupService/xmlType/LSLookupAction.java
2006-11-29 22:25:17 UTC (rev 1787)
@@ -141,6 +141,7 @@
// System.out.println(" LSq0,"+System.currentTimeMillis());
+ double startTime = new
Long(System.currentTimeMillis()).doubleValue();
if(xmlStorageManager instanceof ExistDbXmlrpcXmlStorageManager ||
xmlStorageManager instanceof ExistDbHttpXmlStorageManager) {
edbres = (XmlDbResult)xmlStorageManager.fetch(query);
@@ -157,6 +158,9 @@
//System.out.println(" LSq1," + System.currentTimeMillis());
+ Double endTime = new Long(System.currentTimeMillis()).doubleValue();
+ System.out.println("Actual Time Taken to Query:
"+((endTime-startTime)/1000d)+" secs");
+
logger.debug("LSLookupAction: Got [[" + results.length + "]] results
from DB");
//TODO: if results.length==0 --> return error code or not?
- r1787 - in branches/yi-udel/perfsonar: schema/example-instances/sonar/LS/test src/org/perfsonar/client/testHarness src/org/perfsonar/service/lookupService/xmlType, svnlog, 11/29/2006
Archive powered by MHonArc 2.6.16.