Github user zhouxinyu commented on a diff in the pull request:
https://github.com/apache/incubator-rocketmq/pull/61#discussion_r101196649
--- Diff: store/src/main/java/org/apache/rocketmq/store/CommitLog.java ---
@@ -799,27 +796,18 @@ public long lockTimeMills() {
}
/**
- * Spin util acquired the lock.
+ * acquired the lock and return
*/
- private void lockForPutMessage() {
+ private PutMessageLock lockForPutMessage() {
if
(this.defaultMessageStore.getMessageStoreConfig().isUseReentrantLockWhenPutMessage())
{
--- End diff --
It could be better if we cache the `isUseReentrantLockWhenPutMessage` and
invalidate the dynamic change of this variable.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---