Devs that have worked on large rust applications, how do you avoid needing circular references?

134 points TophatEndermite

I'm interested specifically in server apps. When there's one source of input and one output, I find the borrow checker normally doesn't get in the way. But when dealing continuously with multiple sources of input, all of the designs I've worked with in other languages, have a lot of callbacks and circular references. I can't see an easy way of writing the same design in rust, without using a lot of Rc<RefCell<T>>.

How is this solved in practice? What solutions are used to avoid needing the dreaded circular reference?