changeset 49:7b595f4b341e

modified chapter3.txt
author Nobuyasu Oshiro <dimolto@cr.ie.u-ryukyu.ac.jp>
date Fri, 31 Jan 2014 11:19:32 +0900
parents 6553b7a3717c
children faa708c2958b
files paper/chapter3.tex paper/figures/distributed_read_bench.pdf paper/figures/distributed_write_bench.pdf paper/gnuplot/makegraph_distributed_read.sh paper/gnuplot/makegraph_distributed_write.sh paper/master_paper.pdf
diffstat 6 files changed, 11 insertions(+), 60 deletions(-) [+]
line wrap: on
line diff
--- a/paper/chapter3.tex	Fri Jan 31 09:31:57 2014 +0900
+++ b/paper/chapter3.tex	Fri Jan 31 11:19:32 2014 +0900
@@ -252,65 +252,16 @@
 MessagePackはListを扱うこともできるため, TreeOperationLogで継承されていたIterableの挙動もListを使うことで
 実装を行うことができた.
 
-
-このInterfaceをimplementsしつつシリアライズを行えるクラスとしてNetworkTreeOperationLogを実装した.
-NetworkTreeOperationLogでは次のフィールドを保持する(\ref{src:nettreeoplog}).
-\begin{lstlisting}[frame=lrbt,label=src:nettreeoplog,caption=NetworkTreeOperationLogの実装,numbers=left]
-@Message
-public class NetworkTreeOperationLog implements TreeOperationLog
-{
-  public LinkedList<NetworkTreeOperation> list;
-  public int size;
-  String uuid;
-  String treeName;
-  long timestamp;
-  : // 実装が続いていく
-\end{lstlisting}
-
-
-
+\subsection{ログに対する情報の追加}
+TreeOperationLogをシリアライズ可能な形にした後, 問題が発生した.
+それは, TreeOperationLog事態は木の名前を保持していないというものである.
+そのため, TreeOperationLogだけを受け取っても, そのログがどの木に対して行われるのか
+わからなかった.
+そこで, TreeOperationLogの情報だけでなく, 木の名前とUUID, それとtimestampの情報も付与
+してシリアライズが可能なNetworkTreeOperationLogの実装を行った.
 
-TreeOperationLogの仕様はInterfaceにより定義される.
-\begin{lstlisting}[frame=lrbt,label=src:treeoperationlog,caption=TreeOperationLogの仕様,numbers=left]
-public interface TreeOperationLog extends Iterable<TreeOperation>
-{
-  public TreeOperationLog add(NodePath _p,NodeOperation _op);
-  public TreeOperationLog append(TreeOperationLog _log);
-  public int length();
-}
-\end{lstlisting}
-\verb|Iterable<TreeOperationLog>|を継承しているクラスがTreeOperationLogとなる.
-次にTreeOperationの仕様と, NodeOperation, NodePath の仕様について以下に示す
-\begin{lstlisting}[frame=lrbt,label=src:treeop,caption=TreeOperationの仕様,numbers=left]
-public interface TreeOperation
-{
-  public NodePath getNodePath();
-  public NodeOperation getNodeOperation();
-}
-\end{lstlisting}
-
-\begin{lstlisting}[frame=lrbt,label=src:nodeop,caption=NodeOperationの仕様,numbers=left]
-public interface NodeOperation
-{
-  public Command getCommand();
-  public <T extends EditableNode<T>> Either<Error,T> invoke(T _target);
-  
-  public int getPosition();
-  public String getKey();
-  public ByteBuffer getValue();
-}
-\end{lstlisting}
-
-\begin{lstlisting}[frame=lrbt,label=src:nodepath,caption=Nodepathの仕様,numbers=left]
-public interface NodePath extends Iterable<Integer>
-{
-  public NodePath add(int _pos);
-  public Pair<Integer,NodePath> pop();
-  public int size();
-}
-\end{lstlisting}
-
-
+\subsection{NetworkTreeOperationLogの実装}
+NetworkTreeOperationLogの実装の一部を以下に示す.
 
 
 
Binary file paper/figures/distributed_read_bench.pdf has changed
Binary file paper/figures/distributed_write_bench.pdf has changed
--- a/paper/gnuplot/makegraph_distributed_read.sh	Fri Jan 31 09:31:57 2014 +0900
+++ b/paper/gnuplot/makegraph_distributed_read.sh	Fri Jan 31 11:19:32 2014 +0900
@@ -6,5 +6,5 @@
 set xrange[8:32]
 set xlabel 'number of nodes and clients'
 set ylabel 'time(sec)'
-plot 'read_jungle_errorbar.dat' using 1:2:3 title 'Jungle' lt rgb "blue" with errorbars, 'distributed_read_cassandra_quorum.dat' title "Cassandra Consistency Level Quorum" lt rgb "red" with linespoints, 'distributed_read_cassandra_one.dat' title "Cassandra Consistency Level ONE" lt rgb "dark-red" with linespoints
+plot 'read_jungle_errorbar.dat' using 1:2:3 title 'Jungle' lt rgb "blue" with errorbars, 'read_cassandra_quorum_errorbar.dat' using 1:2:3 title "Cassandra Consistency Level Quorum" lt rgb "red" with errorbars
 EOF
--- a/paper/gnuplot/makegraph_distributed_write.sh	Fri Jan 31 09:31:57 2014 +0900
+++ b/paper/gnuplot/makegraph_distributed_write.sh	Fri Jan 31 11:19:32 2014 +0900
@@ -6,5 +6,5 @@
 set xrange[8:32]
 set xlabel 'number of nodes'
 set ylabel 'time(sec)'
-plot 'write_jungle_errorbar.dat' using 1:2:3 title 'Jungle' lt rgb "blue" with errorbars, 'distributed_write_cassandra_quorum.dat' title "Cassandra Consistency Level Quorum" lt rgb "red" with linespoints,'distributed_write_cassandra_one.dat' title "Cassandra Consistency Level ONE" lt rgb "dark-red" with linespoints
+plot 'write_jungle_errorbar.dat' using 1:2:3 title 'Jungle' lt rgb "blue" with errorbars, 'write_cassandra_quorum_errorbar.dat' using 1:2:3 title "Cassandra Consistency Level Quorum" lt rgb "red" with errorbars
 EOF
Binary file paper/master_paper.pdf has changed