Revision 3277
Added by Jing Tao over 17 years ago
src/edu/ucsb/nceas/metacat/DBQuery.java | ||
---|---|---|
325 | 325 |
"-//W3C//HTML//EN", qformat, out, params, |
326 | 326 |
sessionid); |
327 | 327 |
double endHTMLTransform = System.currentTimeMillis()/1000; |
328 |
logMetacat.warn("The time to transfrom resultset from xml to html format is "
|
|
328 |
logMetacat.warn("The time to transfrom resultset from xml to html format is " |
|
329 | 329 |
+(endHTMLTransform -startHTMLTransform)); |
330 |
MetaCatUtil.writeDebugToFile("---------------------------------------------------------------------------------------------------------------Transfrom xml to html "
|
|
330 |
MetaCatUtil.writeDebugToFile("---------------------------------------------------------------------------------------------------------------Transfrom xml to html " |
|
331 | 331 |
+(endHTMLTransform -startHTMLTransform)); |
332 |
MetaCatUtil.writeDebugToDelimiteredFile(" "+(endHTMLTransform -startHTMLTransform), false); |
|
332 | 333 |
} |
333 | 334 |
catch(Exception e) |
334 | 335 |
{ |
... | ... | |
544 | 545 |
+ (queryExecuteTime - startTime)); |
545 | 546 |
MetaCatUtil.writeDebugToFile("\n\n\n\n\n\nExecute selection query " |
546 | 547 |
+ (queryExecuteTime - startTime)); |
548 |
MetaCatUtil.writeDebugToDelimiteredFile(""+(queryExecuteTime - startTime), false); |
|
547 | 549 |
|
548 | 550 |
boolean tableHasRows = rs.next(); |
549 | 551 |
|
... | ... | |
773 | 775 |
+ (docListTime - startSelectionTime )); |
774 | 776 |
MetaCatUtil.writeDebugToFile("---------------------------------------------------------------------------------------------------------------Total selection: " |
775 | 777 |
+ (docListTime - startSelectionTime )); |
778 |
MetaCatUtil.writeDebugToDelimiteredFile(" "+ (docListTime - startSelectionTime ), false); |
|
776 | 779 |
//if docListResult is not empty, it need to be sent. |
777 | 780 |
if (docListResult.size() != 0) |
778 | 781 |
{ |
... | ... | |
843 | 846 |
(endGetReturnValueFromQueryresultable-startGetReturnValueFromQueryresultable)); |
844 | 847 |
MetaCatUtil.writeDebugToFile("-----------------------------------------Get fields from xml_queryresult(Part1 in return fields) " + |
845 | 848 |
(endGetReturnValueFromQueryresultable-startGetReturnValueFromQueryresultable)); |
849 |
MetaCatUtil.writeDebugToDelimiteredFile(" " + |
|
850 |
(endGetReturnValueFromQueryresultable-startGetReturnValueFromQueryresultable),false); |
|
846 | 851 |
// backup the keys-elements in partOfDoclist to check later |
847 | 852 |
// if the doc entry is indexed yet |
848 | 853 |
Hashtable partOfDoclistBackup = new Hashtable(); |
... | ... | |
864 | 869 |
+ (endExtendedQuery - endGetReturnValueFromQueryresultable)); |
865 | 870 |
MetaCatUtil.writeDebugToFile("-----------------------------------------Get fields from extened query(Part2 in return fields) " |
866 | 871 |
+ (endExtendedQuery - endGetReturnValueFromQueryresultable)); |
872 |
MetaCatUtil.writeDebugToDelimiteredFile(" " |
|
873 |
+ (endExtendedQuery - endGetReturnValueFromQueryresultable), false); |
|
867 | 874 |
//add relationship part part docid list for the documents in partOfDocList |
868 | 875 |
partOfDoclist = addRelationship(partOfDoclist, qspec, dbconn, useXMLIndex); |
869 | 876 |
|
... | ... | |
916 | 923 |
+ (endStoreReturnField -startStoreReturnField)); |
917 | 924 |
MetaCatUtil.writeDebugToFile("-----------------------------------------Insert new record to xml_queryresult(Part4 in return fields) " |
918 | 925 |
+ (endStoreReturnField -startStoreReturnField)); |
926 |
MetaCatUtil.writeDebugToDelimiteredFile(" " |
|
927 |
+ (endStoreReturnField -startStoreReturnField), false); |
|
919 | 928 |
|
920 | 929 |
Enumeration keysE = queryresultDocList.keys(); |
921 | 930 |
while (keysE.hasMoreElements()) |
... | ... | |
937 | 946 |
MetaCatUtil.writeDebugToFile("---------------------------------------------------------------------------------------------------------------"+ |
938 | 947 |
"Total to get return fields " |
939 | 948 |
+ (returnFieldTime - startReturnField)); |
949 |
MetaCatUtil.writeDebugToDelimiteredFile(" "+ (returnFieldTime - startReturnField), false); |
|
940 | 950 |
return resultset; |
941 | 951 |
} |
942 | 952 |
|
... | ... | |
1174 | 1184 |
MetaCatUtil.writeDebugToFile( |
1175 | 1185 |
"Execute extended query " |
1176 | 1186 |
+ (extendedQueryEnd - extendedQueryStart)); |
1187 |
MetaCatUtil.writeDebugToDelimiteredFile(" "+ (extendedQueryEnd - extendedQueryStart), false); |
|
1177 | 1188 |
tableHasRows = rs.next(); |
1178 | 1189 |
while (tableHasRows) { |
1179 | 1190 |
ReturnFieldValue returnValue = new ReturnFieldValue(); |
... | ... | |
1263 | 1274 |
MetaCatUtil.writeDebugToFile( |
1264 | 1275 |
"Get attribute return field " |
1265 | 1276 |
+ (endGetAttribute - startGetAttribute)); |
1277 |
MetaCatUtil.writeDebugToDelimiteredFile(" "+ (endGetAttribute - startGetAttribute), false); |
|
1266 | 1278 |
|
1267 | 1279 |
|
1268 | 1280 |
}//if doclist lenght is great than zero |
... | ... | |
1341 | 1353 |
+ (endRelation - startRelation)); |
1342 | 1354 |
MetaCatUtil.writeDebugToFile("-----------------------------------------Add relationship to return field(part3 in return fields): " |
1343 | 1355 |
+ (endRelation - startRelation)); |
1356 |
MetaCatUtil.writeDebugToDelimiteredFile(" "+ (endRelation - startRelation), false); |
|
1344 | 1357 |
|
1345 | 1358 |
return docListResult; |
1346 | 1359 |
}//addRelation |
Also available in: Unified diff
Add more statement to output performance info in a file in delimitere format