Init README, bugfixes

This commit is contained in:
Max O'Cull 2019-01-19 22:20:57 -05:00
parent f8b0b31f07
commit a8213e3feb
3 changed files with 31 additions and 10 deletions

15
p1/README.txt Normal file
View File

@ -0,0 +1,15 @@
(a) What have you observed to be the fastest Load operation?
[X] Main-memory Load. [ ] MapDB Load
(b) Why do you think that load operation was faster?
Main memory is higher on the memory hiearchy than disk.
(c) What have you observed to be the fastest Select operation?
[ ] File Select [X] Main-memory Select. [ ] MapDB Select
(d) Why do you think that select operation was faster?
Main memory is higher on the memory hiearchy than disk.
(e) What are the benefits of using the embedded database as backend compare to the in-
memory storage?
Much more storage is available on disk via the embedded database than in main memory.

View File

@ -104,6 +104,6 @@ public class project1 {
} }
String select_mapdb(String key){ String select_mapdb(String key){
return mm_map.get(key); return mapdb.get(key);
} }
} }

24
p1/test
View File

@ -1,7 +1,6 @@
#! /bin/bash #! /bin/bash
testCase() { testCase() {
rm ./data.db
java -cp ./target/cs448p1-1.0-SNAPSHOT-jar-with-dependencies.jar -Xmx32m cs448.App "$1" "$2" "$3" java -cp ./target/cs448p1-1.0-SNAPSHOT-jar-with-dependencies.jar -Xmx32m cs448.App "$1" "$2" "$3"
} }
@ -15,22 +14,29 @@ testCase $data_10 $file nm0000001
testCase $data_10 $file nm0028516 testCase $data_10 $file nm0028516
testCase $data_10 $file nm0072686 testCase $data_10 $file nm0072686
testCase $data_10 $file nm0438120 testCase $data_10 $file nm0438120
testCase $data_10 $mem nm0000001
testCase $data_10 $mem nm0028516
testCase $data_10 $mem nm0072686
testCase $data_10 $mem nm0438120
testCase $data_10 $db nm0000001
testCase $data_10 $db nm0028516
testCase $data_10 $db nm0072686
testCase $data_10 $db nm0438120
testCase $data_30 $file nm0000001 testCase $data_30 $file nm0000001
testCase $data_30 $file nm0028516 testCase $data_30 $file nm0028516
testCase $data_30 $file nm0072686 testCase $data_30 $file nm0072686
testCase $data_30 $file nm0438120 testCase $data_30 $file nm0438120
testCase $data_10 $mem nm0000001
testCase $data_10 $mem nm0028516
testCase $data_10 $mem nm0072686
testCase $data_10 $mem nm0438120
testCase $data_30 $mem nm0000001 testCase $data_30 $mem nm0000001
testCase $data_30 $mem nm0028516 testCase $data_30 $mem nm0028516
testCase $data_30 $mem nm0072686 testCase $data_30 $mem nm0072686
testCase $data_30 $mem nm0438120 testCase $data_30 $mem nm0438120
rm ./data.db
testCase $data_10 $db nm0000001
testCase $data_10 $db nm0028516
testCase $data_10 $db nm0072686
testCase $data_10 $db nm0438120
rm ./data.db
testCase $data_30 $db nm0000001 testCase $data_30 $db nm0000001
testCase $data_30 $db nm0028516 testCase $data_30 $db nm0028516
testCase $data_30 $db nm0072686 testCase $data_30 $db nm0072686