Revision 176b8de8 src/PeerSampler/cyclon.c

View differences:

src/PeerSampler/cyclon.c
17 17
#include "../Cache/topocache.h"
18 18
#include "../Cache/cyclon_proto.h"
19 19
#include "../Cache/proto.h"
20
#include "config.h"
20
#include "grapes_config.h"
21 21
#include "grapes_msg_types.h"
22 22

  
23 23
#define DEFAULT_CACHE_SIZE 10
......
88 88
  con = cyclon_context_init();
89 89
  if (!con) return NULL;
90 90

  
91
  cfg_tags = config_parse(config);
92
  res = config_value_int(cfg_tags, "cache_size", &(con->cache_size));
91
  cfg_tags = grapes_config_parse(config);
92
  res = grapes_config_value_int(cfg_tags, "cache_size", &(con->cache_size));
93 93
  if (!res) {
94 94
    con->cache_size = DEFAULT_CACHE_SIZE;
95 95
  }
96
  res = config_value_int(cfg_tags, "sent_entries", &(con->sent_entries));
96
  res = grapes_config_value_int(cfg_tags, "sent_entries", &(con->sent_entries));
97 97
  if (!res) {
98 98
    con->sent_entries = con->cache_size / 2;
99 99
  }
100
  res = config_value_int(cfg_tags, "period", &con->period);
100
  res = grapes_config_value_int(cfg_tags, "period", &con->period);
101 101
  if (!res) {
102 102
    con->period = DEFAULT_PERIOD;
103 103
  }
104
  res = config_value_int(cfg_tags, "bootstrap_period", &con->bootstrap_period);
104
  res = grapes_config_value_int(cfg_tags, "bootstrap_period", &con->bootstrap_period);
105 105
  if (!res) {
106 106
    con->bootstrap_period = DEFAULT_BOOTSTRAP_PERIOD;
107 107
  }
108
  res = config_value_int(cfg_tags, "bootstrap_cycles", &con->bootstrap_cycles);
108
  res = grapes_config_value_int(cfg_tags, "bootstrap_cycles", &con->bootstrap_cycles);
109 109
  if (!res) {
110 110
    con->bootstrap_cycles = DEFAULT_BOOTSTRAP_CYCLES;
111 111
  }

Also available in: Unified diff