when i was joung, i was doing a microkernel based os.
later my interest focused on telco so i switched to freerouter.
when it happened, i was a fresh 2*ccie. with a deep interest in protocols.
that's the background, and this is how the this project began around 2009.
freerouter is a monolitic design because i noticed that in telco,
everything have a connection with every other thing, so this design fits better.
i loved the microkernel idea so i decided to separate things
as much as i can, and use as much of threads as i can, and also
use pipelines between them where possible because it allows paralell
execution of different things without locking.
later i saw that some kind of things cannot be done effectively
this way, but still wanted to avoid locking between threads, so
i introduced an asynchron notificaiton mechanism between the threads,
so a thread prepares it's changes and can wake up the other easily.
if that other already does something, can check if missed a notification
before going to sleep again. and of cource i also use to as much as i can.
so these are the basic design principles in freerouter.
in practice, a single bgp peer have a bgp sender, a bgp
receiver thread, and an these communicate though pipes with the
underlaying tcp worker thread, and notifies the bestpath
calculator thread when finished one update processing.
this means that it scales very well to any number of peers.
the same applies to the forwarder threads, you can set
the number of them, depending on your amount of traffic.

freeRouter nop.hu