Igor Putovny
da65a073c5
Add debugging logs
2024-05-30 12:30:00 +02:00
Igor Putovny
ade731e02a
Rename variables of type protocol in order to be consistent with the rest of the codebase
2024-05-30 12:30:00 +02:00
Igor Putovny
4621925ff4
Create and assign net to default route
2024-05-30 12:30:00 +02:00
Igor Putovny
0c1ac9674a
Change a few logs
2024-05-30 12:30:00 +02:00
Igor Putovny
9d6d8b1adb
Refactor functions for comparing buckets and computing union and intersection of buckets
2024-05-30 12:30:00 +02:00
Igor Putovny
dcf0038fd0
Run correct aggregation (by nets or by attributes) according to configuration
2024-05-30 12:30:00 +02:00
Igor Putovny
ecfb73332a
Collect prefixes in trie after aggregation and export new routes
2024-05-30 12:30:00 +02:00
Igor Putovny
14d82bc053
Remove const from aggregator_bucket pointers in trie nodes
2024-05-30 12:30:00 +02:00
Igor Putovny
b265df526c
Refactor printing prefixes in trie
2024-05-30 12:30:00 +02:00
Igor Putovny
79981d2ad2
Bugfix
...
Due to wrong cast of void pointer, pointers to potential buckets
were compared and eventually sorted in wrong order, thus assigning
wrong buckets to trie nodes.
This caused some trie nodes to stay in trie even though they should
have been removed. Consequently, trie contained superfluos prefixes
after the algorithm finished.
Since pointers were never dereferenced, only compared by their numeric
values in the comparator function, program did not crash (even though
pointers could be NULL because of the incorrect cast to double pointer
and single dereference).
2024-05-30 12:30:00 +02:00
Igor Putovny
03d71cb98c
Remove unused code
2024-05-30 12:30:00 +02:00
Igor Putovny
e40ea2b98e
Create default empty route for aggregation
2024-05-30 12:30:00 +02:00
Igor Putovny
f85e3a6ae5
Add more assertions
2024-05-30 12:30:00 +02:00
Igor Putovny
80f2d6e0c5
Make pointer to aggregator bucket const
2024-05-30 12:30:00 +02:00
Igor Putovny
fccb5140e2
Do not discard bucket from internal nodes
2024-05-30 12:30:00 +02:00
Igor Putovny
4a1f4e837d
Do not assign bucket of any prefix to the root node
2024-05-30 12:30:00 +02:00
Igor Putovny
299f9e80f7
Create event to run ORTC algorithm exactly once
2024-05-30 12:30:00 +02:00
Igor Putovny
2b6cfd2065
Run ORTC algorithm
2024-05-30 12:30:00 +02:00
Igor Putovny
e68363df0f
Add assertions and general code improvements
2024-05-30 12:30:00 +02:00
Igor Putovny
f1d280981e
Remove unused code
2024-05-30 12:30:00 +02:00
Igor Putovny
5bde9a161a
Rename constant
2024-05-30 12:30:00 +02:00
Igor Putovny
2b18dea7c2
Fix how bucket for new leaf nodes is chosen
2024-05-30 12:30:00 +02:00
Igor Putovny
98621a741a
Use net_addr_ip4 instead of ip4_addr for printing prefixes
2024-05-30 12:30:00 +02:00
Igor Putovny
6522bc04e4
Remove unused code
2024-05-30 12:30:00 +02:00
Igor Putovny
ef6a526588
Add comments
2024-05-30 12:30:00 +02:00
Igor Putovny
4352095801
Change order of parameters in a few functions
2024-05-30 12:30:00 +02:00
Igor Putovny
dca392e7c6
Simplify delete_trie() function
2024-05-30 12:30:00 +02:00
Igor Putovny
1cf73f74ac
Assign bucket of ancestor node to leaf node
2024-05-30 12:30:00 +02:00
Igor Putovny
7213cc08f3
Fix incorrect implementation of the third pass
2024-05-30 12:30:00 +02:00
Igor Putovny
2d2354f54e
Assign route bucket only to the last inserted node
2024-05-30 12:30:00 +02:00
Igor Putovny
1712d83c01
Fix argument order in several functions
2024-05-30 12:30:00 +02:00
Igor Putovny
ec1eb83bf0
Add a few comments, print prefixes after aggregation
2024-05-30 12:30:00 +02:00
Igor Putovny
7657d05592
Extend remove_node() with deleting root node
2024-05-30 12:30:00 +02:00
Igor Putovny
26ac6dca5c
Fix aggregator_bucket_unionize()
...
The last two while loops were incorrectly placed inside the first while loop
2024-05-30 12:30:00 +02:00
Igor Putovny
9954b24f57
Fix const warning, add few comments
2024-05-30 12:30:00 +02:00
Igor Putovny
f7161a875f
Delete trie during aggregator shutdown
2024-05-30 12:30:00 +02:00
Igor Putovny
6d5e75e46d
Refactor and fix aggregator_bucket_unionize()
2024-05-30 12:30:00 +02:00
Igor Putovny
45c7a5463e
Fix aggregator_bucket_intersect(), add comments and fix naming
2024-05-30 12:30:00 +02:00
Igor Putovny
d046a0a42f
Remove unused code
2024-05-30 12:30:00 +02:00
Igor Putovny
5a933c6fe5
Add new implementation of third_pass() and remove old implementation
2024-05-30 12:30:00 +02:00
Igor Putovny
ca4a1dc9d3
Move trie initialization to aggregator_start()
2024-05-30 12:30:00 +02:00
Igor Putovny
7d93e8b7d3
Fix previous version, aggregator is now stable but untested
2024-05-30 12:30:00 +02:00
Igor Putovny
2d822231d4
Implement basics of prefix aggregation functionality
2024-05-30 12:30:00 +02:00
Maria Matejka
ccc5166280
Aggregator: Fixed hashing of adata
2024-05-30 12:30:00 +02:00
Maria Matejka
a582ee9c6d
Aggregator moved to a separate protocol
...
Also updated data structures and reconfigure.
Known bug: the hash doesn't take adata into account. Needs fixing!
2024-05-30 12:30:00 +02:00