gtully commented on code in PR #5653: URL: https://github.com/apache/activemq-artemis/pull/5653#discussion_r2066068978
########## artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/QueueImpl.java: ########## @@ -747,7 +747,7 @@ public void refUp(MessageReference messageReference) { } } if (pagingStore != null) { - if (owner != null && pagingStore != owner) { + if (isInternalQueue() && owner != null && pagingStore != owner) { Review Comment: the problem I see is that it is a change of behaviour. the memory model as I understand it, is that address accumulate memory (based on the message size), queues accumulate references. That is simple for any cast addresses, and for multicast addresses, the message is accounted for once and any reference will retain that. by accounting twice, we break that model (hence this issue). Now there is a case for treating a mirror as a special case, but I don't know if there is a good reason for that, it takes a copy which is different but that could be an increment to the address usage. I think that would be consistent with the existing model, but may be tricky to implement. If we say a mirror is just a snf and we change all snfs to accumulate usage rather than just a reference, it is a big change. I think it may be the wrong path, or it will need some good explanation b/c in many cases, paging will kick in early which wont be expected. Sizing a broker is difficult, so having a good and simple memory model is vital imho. -- 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: gitbox-unsubscr...@activemq.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: gitbox-unsubscr...@activemq.apache.org For additional commands, e-mail: gitbox-h...@activemq.apache.org For further information, visit: https://activemq.apache.org/contact