amqpprox icon indicating copy to clipboard operation
amqpprox copied to clipboard

DNSHostnameMapper upgrade to C++17

Open alaric opened this issue 4 years ago • 1 comments

Now we're using C++17 for this project, the boost::shared_mutex can be converted over to a std::shared_mutex.

alaric avatar Jan 18 '21 18:01 alaric

We're using boost::upgrade_to_unique_lock, which as far as I can tell didn't make it into C++17. Avoiding the boost::shared_mutex would require acquiring a unique_lock at the start of the DNSHostnameMapper::prime method.

This may actually make sense, I'm getting the feeling that two parallel calls to prime may end up deadlocked. Unsure if upgrade_to_unique_lock does something special here.

adamncasey avatar Jun 30 '21 15:06 adamncasey