summaryrefslogtreecommitdiff
path: root/ot_sync.c
diff options
context:
space:
mode:
authorerdgeist <>2008-10-04 05:40:51 +0000
committererdgeist <>2008-10-04 05:40:51 +0000
commite534db03c6877f8ac0559f63840e9a00e9bd43bf (patch)
tree811181b9b39d0484e28eb25cbb9f2eea094978e2 /ot_sync.c
parent8cbfc8602c73e55770f3c06d8ea42758b22a0401 (diff)
added live sync code
added a config file parser added tracker id changed WANT_CLOSED_TRACKER and WANT_BLACKLIST into WANT_ACCESS_WHITE and WANT_ACCESS_BLACK changed WANT_TRACKER_SYNC to WANT_SYNC_BATCH and added WANT_SYNC_LIVE added an option to switch off fullscrapes cleaned up many internal hardcoded values, like PROTO_FLAG,
Diffstat (limited to 'ot_sync.c')
-rw-r--r--ot_sync.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ot_sync.c b/ot_sync.c
index 5f772fb..4beb60d 100644
--- a/ot_sync.c
+++ b/ot_sync.c
@@ -23,7 +23,7 @@
23#include "ot_stats.h" 23#include "ot_stats.h"
24#include "ot_iovec.h" 24#include "ot_iovec.h"
25 25
26#ifdef WANT_TRACKER_SYNC 26#ifdef WANT_SYNC_BATCH
27 27
28#define OT_SYNC_CHUNK_SIZE (512*1024) 28#define OT_SYNC_CHUNK_SIZE (512*1024)
29 29
@@ -141,7 +141,7 @@ static void * sync_worker( void * args) {
141 ot_tasktype tasktype = TASK_SYNC_OUT; 141 ot_tasktype tasktype = TASK_SYNC_OUT;
142 ot_taskid taskid = mutex_workqueue_poptask( &tasktype ); 142 ot_taskid taskid = mutex_workqueue_poptask( &tasktype );
143 sync_make( &iovec_entries, &iovector ); 143 sync_make( &iovec_entries, &iovector );
144 stats_issue_event( EVENT_SYNC_OUT, 1, iovec_length( &iovec_entries, &iovector) ); 144 stats_issue_event( EVENT_SYNC_OUT, FLAG_TCP, iovec_length( &iovec_entries, &iovector) );
145 if( mutex_workqueue_pushresult( taskid, iovec_entries, iovector ) ) 145 if( mutex_workqueue_pushresult( taskid, iovec_entries, iovector ) )
146 iovec_free( &iovec_entries, &iovector ); 146 iovec_free( &iovec_entries, &iovector );
147 } 147 }