0
0
mirror of https://gitlab.nic.cz/labs/bird.git synced 2024-11-08 12:18:42 +00:00

Run aggregation only once (temporary solution)

This commit is contained in:
Igor Putovny 2024-06-04 12:25:54 +02:00
parent e5e35971b0
commit 7eb9175a09
2 changed files with 10 additions and 1 deletions

View File

@ -919,7 +919,14 @@ static void
aggregate_on_settle_timer(struct settle *s) aggregate_on_settle_timer(struct settle *s)
{ {
struct aggregator_proto *p = SKIP_BACK(struct aggregator_proto, p, s->tm.data); struct aggregator_proto *p = SKIP_BACK(struct aggregator_proto, p, s->tm.data);
run_aggregation(p);
if (!p->aggr_done)
{
run_aggregation(p);
p->aggr_done = 1;
}
else
log("Aggregation is already finished");
} }
/* /*
@ -1563,6 +1570,7 @@ aggregator_start(struct proto *P)
p->trie_slab = sl_new(p->p.pool, sizeof(struct trie_node)); p->trie_slab = sl_new(p->p.pool, sizeof(struct trie_node));
p->root = create_new_node(p->trie_slab); p->root = create_new_node(p->trie_slab);
p->root->depth = 1; p->root->depth = 1;
p->aggr_done = 0;
struct network *default_net = NULL; struct network *default_net = NULL;

View File

@ -76,6 +76,7 @@ struct aggregator_proto {
struct settle aggr_timer; struct settle aggr_timer;
int before_count; int before_count;
int after_count; int after_count;
int aggr_done;
}; };
enum aggr_item_type { enum aggr_item_type {