okuyamaFuseからデバッグを取り外し
@@ -1,6 +1,6 @@ | ||
1 | 1 | #!/bin/sh |
2 | 2 | |
3 | -LD_LIBRARY_PATH=./:/usr/local/lib java -classpath ./okuyamaFuse-0.0.1.jar:./fuse-j.jar:./commons-logging-1.0.4.jar:./okuyama-0.9.4.jar:./javamail-1.4.1.jar:./log4j-1.2.14.jar \ | |
3 | +LD_LIBRARY_PATH=./:/usr/local/lib java -classpath ./okuyamaFuse-0.0.2.jar:./fuse-j.jar:./commons-logging-1.0.4.jar:./okuyama-0.9.5.jar:./javamail-1.4.1.jar:./log4j-1.2.14.jar \ | |
4 | 4 | -Dorg.apache.commons.logging.Log=fuse.logging.FuseLog \ |
5 | 5 | -Dfuse.logging.level=ERROR -Xmx1548m -Xms1524m -server -XX:+UseConcMarkSweepGC -XX:+CMSParallelRemarkEnabled -XX:+UseParNewGC \ |
6 | - fuse.okuyamafs.OkuyamaFuse -f -o direct_io -o allow_other $1 $2 1>> ./okufs.log 2>>./okufs.log | |
\ No newline at end of file | ||
6 | + fuse.okuyamafs.OkuyamaFuse -f -o direct_io -o allow_other $1 $2 1>> ./okufs.log 2>>./okufs.log |
@@ -168,7 +168,6 @@ | ||
168 | 168 | |
169 | 169 | public int readValue(String key, long start, int offset, String realKeyNodeNo, ByteBuffer buf) throws Exception { |
170 | 170 | //List dataReadKeyList = new ArrayList(); |
171 | -long start1 = System.nanoTime(); | |
172 | 171 | |
173 | 172 | String[] dataReadKeyList = null; |
174 | 173 | boolean allDataNull = true; |
@@ -205,7 +204,6 @@ | ||
205 | 204 | |
206 | 205 | //replaceDataBuf = new byte[OkuyamaFilesystem.blockSize * dataReadKeyListSize]; |
207 | 206 | |
208 | -long start11 = System.nanoTime(); | |
209 | 207 | if (CoreMapFactory.factoryType == 2) { |
210 | 208 | |
211 | 209 | // okuyamaの場合事前にgetMultiByteでデータを取得しておく |
@@ -216,9 +214,6 @@ | ||
216 | 214 | if (dataReadKeyListSize > 1) { |
217 | 215 | //Map multiReadRet = this.getMultiValue(keyList); |
218 | 216 | Map multiReadRet = this.getMultiValue(dataReadKeyList); |
219 | -long end11 = System.nanoTime(); | |
220 | -System.out.println("S1-1=" + (end11 - start11) / 1000); | |
221 | -long start2 = System.nanoTime(); | |
222 | 217 | int totalReadLen = 0; |
223 | 218 | if (multiReadRet != null) { |
224 | 219 | for (int i = 0; i < dataReadKeyListSize; i++) { |
@@ -237,8 +232,6 @@ | ||
237 | 232 | totalReadLen = totalReadLen + readData.length; |
238 | 233 | } |
239 | 234 | } |
240 | -long end2 = System.nanoTime(); | |
241 | -System.out.println("S2=" + (end2 - start2) / 1000); | |
242 | 235 | |
243 | 236 | return totalReadLen; |
244 | 237 | } else { |
@@ -287,8 +280,6 @@ | ||
287 | 280 | retData = new byte[realWritePoint]; |
288 | 281 | System.arraycopy(replaceDataBuf, bufReadPoint, retData, 0, realWritePoint); |
289 | 282 | } |
290 | -long end3 = System.nanoTime(); | |
291 | -System.out.println("S3=" + (end3 - start1) / 1000); | |
292 | 283 | |
293 | 284 | return -1; |
294 | 285 |
@@ -469,7 +460,6 @@ | ||
469 | 460 | |
470 | 461 | lastSetKey = dataReadKeyList[idx]; |
471 | 462 | } |
472 | - | |
473 | 463 | ((OkuyamaFsMap)dataMap).putMultiBytes(putDataList); |
474 | 464 | } |
475 | 465 |
@@ -375,23 +375,15 @@ | ||
375 | 375 | |
376 | 376 | // Stripingの場合で処理がことなる |
377 | 377 | if (BufferedOkuyamaClient.stripingDataBlock == false) { |
378 | -//long start = System.nanoTime(); | |
379 | 378 | Object[] realClientRet = this.client.readByteValue(key); |
380 | -//long end = System.nanoTime(); | |
381 | 379 | |
382 | 380 | if (realClientRet != null && realClientRet[0].equals("true")) { |
383 | 381 | |
384 | 382 | value = (byte[])realClientRet[1]; |
385 | -//System.out.println("time1=" + (end - start) + " len=" + value.length + " Key=" + key); | |
386 | 383 | } |
387 | - | |
388 | - | |
389 | 384 | } else { |
390 | 385 | // StripingBlock; |
391 | -long start = System.nanoTime(); | |
392 | 386 | value = this.readStripingBlock(key); |
393 | -long end = System.nanoTime(); | |
394 | -System.out.println("time2=" + (end - start)); | |
395 | 387 | if (value.length == 0) value = null; |
396 | 388 | } |
397 | 389 | } |
@@ -423,7 +415,6 @@ | ||
423 | 415 | |
424 | 416 | try { |
425 | 417 | |
426 | -//long start = System.nanoTime(); | |
427 | 418 | int strpngIndex = 0; |
428 | 419 | for (int idx = 0; idx < BufferedOkuyamaClient.stripingLevel / 4; idx++) { |
429 | 420 | stripingDataClient[0].requestReadByteValue(key+"\t"+strpngIndex); |
@@ -436,11 +427,9 @@ | ||
436 | 427 | strpngIndex++; |
437 | 428 | |
438 | 429 | boolean endRead = false; |
439 | -long start = System.nanoTime(); | |
440 | - | |
430 | + | |
441 | 431 | Object[] stripingRet1 = stripingDataClient[0].responseReadByteValue(key+"\t"+(strpngIndex - 4)); |
442 | 432 | if (endRead == false && stripingRet1[0].equals("true")) { |
443 | -System.out.println("1Len=" + ((byte[])stripingRet1[1]).length); | |
444 | 433 | baos.write((byte[])stripingRet1[1]); |
445 | 434 | } else { |
446 | 435 | endRead = true; |
@@ -448,7 +437,6 @@ | ||
448 | 437 | |
449 | 438 | Object[] stripingRet2 = stripingDataClient[1].responseReadByteValue(key+"\t"+(strpngIndex - 3)); |
450 | 439 | if (endRead == false && stripingRet2[0].equals("true")) { |
451 | -System.out.println("2Len=" + ((byte[])stripingRet2[1]).length); | |
452 | 440 | baos.write((byte[])stripingRet2[1]); |
453 | 441 | } else { |
454 | 442 | endRead = true; |
@@ -456,7 +444,6 @@ | ||
456 | 444 | |
457 | 445 | Object[] stripingRet3 = stripingDataClient[2].responseReadByteValue(key+"\t"+(strpngIndex - 2)); |
458 | 446 | if (endRead == false && stripingRet3[0].equals("true")) { |
459 | -System.out.println("3Len=" + ((byte[])stripingRet3[1]).length); | |
460 | 447 | baos.write((byte[])stripingRet3[1]); |
461 | 448 | } else { |
462 | 449 | endRead = true; |
@@ -464,18 +451,13 @@ | ||
464 | 451 | |
465 | 452 | Object[] stripingRet4 = stripingDataClient[3].responseReadByteValue(key+"\t"+(strpngIndex - 1)); |
466 | 453 | if (endRead == false && stripingRet4[0].equals("true")) { |
467 | -System.out.println("4Len=" + ((byte[])stripingRet4[1]).length); | |
468 | 454 | baos.write((byte[])stripingRet4[1]); |
469 | 455 | } else { |
470 | 456 | endRead = true; |
471 | 457 | } |
472 | -long end = System.nanoTime(); | |
473 | -System.out.println("StripingGet=" + (end - start)); | |
474 | 458 | |
475 | 459 | if (endRead == true) break; |
476 | 460 | } |
477 | -//long end2 = System.nanoTime(); | |
478 | -//System.out.println("2=" + (end2 - start2)); | |
479 | 461 | |
480 | 462 | } catch (Exception e) { |
481 | 463 | throw e; |
@@ -25,8 +25,8 @@ | ||
25 | 25 | public volatile static int blockSizeAssist = 50; |
26 | 26 | |
27 | 27 | //public volatile static int blockSize = 1024*512;//5200; // Blockサイズ |
28 | - public volatile static int blockSize = 1024*14;//1024*63; //1024*17; //5200; // Blockサイズ | |
29 | -//20480 | |
28 | + public volatile static int blockSize = 5632; // Blockサイズ | |
29 | + | |
30 | 30 | |
31 | 31 | public volatile static int writeBufferSize = 1024 * 1024 * 5 + 1024; |
32 | 32 |
@@ -831,10 +831,7 @@ | ||
831 | 831 | String pathInfoStr = (String)client.getPathDetail(trimToPath); |
832 | 832 | |
833 | 833 | String[] pathInfo = pathInfoStr.split("\t"); |
834 | -//long start = System.nanoTime(); | |
835 | 834 | int readLen = client.readValue(trimToPath, offset, buf.limit(), pathInfo[pathInfo.length - 2], buf); |
836 | -//long end = System.nanoTime(); | |
837 | -//System.out.println("ALL read=" + (end - start) / 1000 + " micro Len=" + readLen); | |
838 | 835 | |
839 | 836 | if (readLen == -1 || readLen < 1) { |
840 | 837 |
@@ -410,7 +410,7 @@ | ||
410 | 410 | |
411 | 411 | public Map getMultiBytes(Object[] keyList) { |
412 | 412 | //return (byte[])dumm.get(type + "\t" + (String)key); |
413 | -long start = System.nanoTime(); | |
413 | + //long start = System.nanoTime(); | |
414 | 414 | Map retMap = new HashMap(); |
415 | 415 | Map okuyamaDataMap = new HashMap(); |
416 | 416 |
@@ -485,8 +485,8 @@ | ||
485 | 485 | } catch (Exception e) { |
486 | 486 | e.printStackTrace(); |
487 | 487 | } |
488 | -long end = System.nanoTime(); | |
489 | -System.out.println("Key count=" + keyList.length + " Time=" + ((end - start) / 1000)); | |
488 | + //long end = System.nanoTime(); | |
489 | + //System.out.println("Key count=" + keyList.length + " Time=" + ((end - start) / 1000)); | |
490 | 490 | return retMap; |
491 | 491 | } |
492 | 492 |
@@ -785,10 +785,7 @@ | ||
785 | 785 | if (client == null) client = new BufferedOkuyamaClient(this.factory.getClient(300*1000)); |
786 | 786 | |
787 | 787 | clientUseCount++; |
788 | -//long start = System.nanoTime(); | |
789 | 788 | boolean ret = client.sendByteValue((String)request[0], OkuyamaFsMapUtil.dataCompress((byte[])request[1])); |
790 | -//long end = System.nanoTime(); | |
791 | -//System.out.println("put=" + ((end - start) / 1000 / 1000) + " Len=" + ((byte[])request[1]).length); | |
792 | 789 | if (ret) { |
793 | 790 | this.responseBox.put(new Integer(0)); |
794 | 791 | } else { |
@@ -4,7 +4,7 @@ | ||
4 | 4 | <property name="project.title" value="okuyamaFuse" /> |
5 | 5 | <property name="src.dir" value="src" /> |
6 | 6 | <property name="build.dir" value="classes" /> |
7 | - <property name="version" value="0.0.1" /> | |
7 | + <property name="version" value="0.0.2" /> | |
8 | 8 | <property name="lib.dir" value="lib"/> |
9 | 9 | |
10 | 10 | <!-- Use Project Lib --> |