24 #ifndef GRAPHLAB_FAKE_CHANDY_MISRA_HPP
25 #define GRAPHLAB_FAKE_CHANDY_MISRA_HPP
27 #include <graphlab/rpc/dc_dist_object.hpp>
28 #include <graphlab/rpc/distributed_event_log.hpp>
29 #include <graphlab/engine/chandy_misra_interface.hpp>
30 #include <graphlab/logger/assertions.hpp>
31 #include <graphlab/parallel/pthread_tools.hpp>
32 #include <graphlab/graph/graph_basic_types.hpp>
33 #include <graphlab/macros_def.hpp>
40 template <
typename GraphType>
41 class fake_chandy_misra:
public chandy_misra_interface<GraphType> {
43 typedef typename GraphType::local_vertex_type local_vertex_type;
44 typedef typename GraphType::local_edge_type local_edge_type;
47 typedef typename GraphType::lvid_type
lvid_type;
49 typedef fake_chandy_misra<GraphType> dcm_type;
51 boost::function<void(lvid_type)> callback;
52 boost::function<void(lvid_type)> hors_doeuvre_callback;
55 inline fake_chandy_misra(distributed_control &dc,
57 boost::function<
void(
lvid_type)> callback,
58 boost::function<
void(
lvid_type)> hors_doeuvre_callback = NULL
61 hors_doeuvre_callback(hors_doeuvre_callback){
64 size_t num_clean_forks()
const {
68 void make_philosopher_hungry_per_replica(
lvid_type p_id) {
72 void philosopher_stops_eating_per_replica(
lvid_type p_id) {
78 #include <graphlab/macros_undef.hpp>