rocketmq icon indicating copy to clipboard operation
rocketmq copied to clipboard

TransientStorePool only remain 0 sheets

Open tangtangsara opened this issue 6 years ago • 5 comments

BUG REPORT version 4.7.1

config file :

maxMessageSize=8388608 brokerRole=ASYNC_MASTER flushDiskType=ASYNC_FLUSH aclEnable=false transientStorePoolEnable=true transientStorePoolSize=1 sendMessageThreadPoolNums=16 useReentrantLockWhenPutMessage=true

in store.log on server : 2020-11-19 10:11:43 WARN AllocateMappedFileService - Use default implementation. 2020-11-19 10:11:43 WARN AllocateMappedFileService - TransientStorePool only remain 0 sheets.

and same time , clients error message [REJECTREQUEST]system busy, start flow control for a while

can not set transientStorePoolSize=1 ? must be greate than 1 ?

tangtangsara avatar Nov 19 '20 06:11 tangtangsara

default value of transientStorePoolSize is 5, default size value is 1g

maixiaohai avatar Nov 19 '20 14:11 maixiaohai

You are not using transientStorePool!Check config careful. Ref bellow code:

if (messageStore.getMessageStoreConfig().isTransientStorePoolEnable()) {
	try {
	} catch (RuntimeException e) {
		log.warn("Use default implementation.");
	}
}

Only transientStorePoolEnable=true,log will print Use default implementation.

gaoyf avatar Nov 20 '20 06:11 gaoyf

You are not using transientStorePool!Check config careful. Ref bellow code:

if (messageStore.getMessageStoreConfig().isTransientStorePoolEnable()) {
	try {
	} catch (RuntimeException e) {
		log.warn("Use default implementation.");
	}
}

Only transientStorePoolEnable=true,log will print Use default implementation.

I make a mistake . I copy config file after the error happen , and then disable transientStorePoolEnable.

the config is transientStorePoolEnable=true when error happens

@gaoyf

tangtangsara avatar Nov 20 '20 16:11 tangtangsara

default value of transientStorePoolSize is 5, default size value is 1g

i know default value of transientStorePoolSize is 5, and default size is 1g. i want to determine set to 1 Is it allowed?

tangtangsara avatar Nov 20 '20 16:11 tangtangsara

如果你不想用transientStorePool机制,禁止就行了,它不会消耗内存。 如果想用,就不要设为1,因为每个MappedFile持有一个从transientStorePool借出大小为1G堆外内存。 如果transientStorePoolSize设为1,那么pool里只有一个1G的堆外内存,在MappedFile写满切换时势必受到影响。

gaoyf avatar Nov 23 '20 01:11 gaoyf