Closed jmalloc closed 2 years ago
/cc @danilvpetrov
I've accidentally lost the 'graceful shutdown' behaviour of the notification system in this PR. I'll need to update it so that when the peer is stopped gracefully any running notification handlers are allowed to finish before the peer.Done()
channel is closed. Clearly this also needs some functional tests.
This PR is the first step of an internal refactor that attempts to reduce the complexity of the various subsystems by reducing the responsibilities of the
rinqamqp
package to marshalling and routing topology configuration.For notifications, all communication between Rinq's core logic layer and the AMQP "transport" is now handled via interfaces in the
transport
package.logging
package has been added underrinq/internal
to encapsulate all of the non-debug level logging. Additionally, the notification-related elements of theopentr
have been changed such that these two packages now offer a similar set of functions to make it more obvious that certain logging messages and OpenTracing spans are concerned with the same Rinq events. In the future, it's likely ametrics
package will offer a similar interface.