masaori335 commented on code in PR #9442:
URL: https://github.com/apache/trafficserver/pull/9442#discussion_r1111387608


##########
iocore/hostdb/P_RefCountCache.h:
##########
@@ -169,7 +170,7 @@ template <class C> class RefCountCachePartition
 
   hash_type &get_map();
 
-  Ptr<ProxyMutex> lock; // Lock
+  ink_rwlock lock = PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP;

Review Comment:
   Pretty interesting change. Could you use `std::shared_mutex` here? 
   We can do it later, but using `std::shared_mutex` will make it easier to 
apply `ts::bravo::shared_mutex` or other reader-writer lock improvements in the 
future, IMO.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to