Github user mtaylor commented on the issue:
https://github.com/apache/activemq-artemis/pull/1486
Nice catch on this @dudaerich. I think @michaelandrepearce suggestions
make sense. The code needs a little refactor. Remove the double check. There
is actually another leak here. First line in the sendReplicatePacket()
```java
if (!enabled) return null.
```
Can you also fix this. Cheers.
---
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.
---