-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/17423/#review33233
-----------------------------------------------------------


Great stuff!


src/messages/state.proto
<https://reviews.apache.org/r/17423/#comment62599>

    Kill extra lines.



src/state/log.cpp
<https://reviews.apache.org/r/17423/#comment62600>

    s/startd/started/



src/state/log.cpp
<https://reviews.apache.org/r/17423/#comment62601>

    We can kill this if the following patch is out:
    https://reviews.apache.org/r/17476/
    
    Replace it with a Sequence object.



src/state/log.cpp
<https://reviews.apache.org/r/17423/#comment62602>

    Ditto.



src/state/log.cpp
<https://reviews.apache.org/r/17423/#comment62605>

    Kill spaces.



src/state/log.cpp
<https://reviews.apache.org/r/17423/#comment62622>

    Comments about why atomicity can be achieved here might be great. For 
example, I may wonder: is it possible that some other writer gets elected and 
writes the same variable ahead in the log while this writer does not know about 
it and somehow is writing a 'hole' in the log (and succeeds). In that case, the 
other writer's append may not be atomic.
    
    I guess one important invariant here is: when a writer successfully appends 
a value to the log (at position p), all values at positions prior to p should 
have been agreed and properly replayed (thus reflected in the in-memory 
snapshots).



src/tests/log_tests.cpp
<https://reviews.apache.org/r/17423/#comment62623>

    What's this:)



src/tests/state_tests.cpp
<https://reviews.apache.org/r/17423/#comment62627>

    extends from TemporaryDirectoryTest?



src/tests/state_tests.cpp
<https://reviews.apache.org/r/17423/#comment62628>

    so that you don't have to do this if TemporaryDirectoryTest is used?


- Jie Yu


On Jan. 27, 2014, 9:33 p.m., Benjamin Hindman wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/17423/
> -----------------------------------------------------------
> 
> (Updated Jan. 27, 2014, 9:33 p.m.)
> 
> 
> Review request for mesos, Ben Mahler and Jie Yu.
> 
> 
> Repository: mesos-git
> 
> 
> Description
> -------
> 
> This is done in C++11, I've converted to C++03 in 
> https://reviews.apache.org/r/17424.
> 
> Note that this does not implement diffs but that's probably okay for our 
> initial use case. This also does not implement caching so all state entries 
> are stored in memory, which is also okay for our initial use case. Finally, 
> this does not implement defragmentation which again is probably okay for our 
> use case. These are captured as TODOs in the code.
> 
> Also, this uses a 'sequence' operation which will be replaced with work being 
> done by Jie Yu.
> 
> 
> Diffs
> -----
> 
>   src/Makefile.am d58b46e99e0a041cf2a26abe44bbd1504a9539c0 
>   src/messages/state.proto 7f7a8a505d6f24b01fec0c3ad47b0e15b2b17ffa 
>   src/state/log.hpp PRE-CREATION 
>   src/state/log.cpp PRE-CREATION 
>   src/tests/log_tests.cpp e493af4f2f2435efe168d07acd267b61afd37fe4 
>   src/tests/state_tests.cpp 03c538861a88d3a07e2468dce5553eeb3acc9243 
> 
> Diff: https://reviews.apache.org/r/17423/diff/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Benjamin Hindman
> 
>

Reply via email to