In absolute terms AIO is faster than NIO. That's the whole reason we
created the activemq-artemis-native integration layer.

However, whether this difference actually impacts your deployment depends
on whether disk writes are a bottleneck. Therefore, it's really impossible
for us to answer this question in a holistic way.

I do believe Netty's direct memory usage is configurable, but I don't know
the details.


Justin

On Thu, Feb 20, 2025 at 12:45 AM Franck Malka <fma...@modulo.co.il> wrote:

> Hi,
>
> Yes, I use ASYNCIO and libAIO.
> I have seen performance is better than NIO.
> You think I can achieve the same performance with NIO?
> Do you think I can disable netty direct memory?
>
> -Franck.
>
> On Thu, Feb 20, 2025 at 8:05 AM Justin Bertram <jbert...@apache.org>
> wrote:
>
> > It's really impossible to say whether or not this is some kind of memory
> > leak which might be fixed in a later release. However, I do know that
> > 2.14.0 was released over 4 years ago now and there's been almost 3,000
> > commits between then and 2.39.0 (i.e. the current release).
> >
> > Regarding the specifics of your problem...Do you really mean "native"
> > memory or are you talking about "direct" memory?
> >
> > The only thing which I think would be using native memory is the
> > artemis-native JNI library [1] which serves as an interface between the
> > broker and libAIO on Linux. Are you using this?
> >
> > On the other hand, Netty is a big user of direct memory. Artemis 2.14.0
> > shipped 4.1.48.Final and 2.39.0 shipped 4.1.115.Final so there's a fairly
> > big difference there.
> >
> > Generally speaking we encourage folks to stay on the latest release
> > possible so when they have issues we can rule out things that have
> already
> > been fixed. Are you able to at least try the latest release to see if it
> > resolves the issue you're seeing (assuming it is a legitimate problem)?
> If
> > not, could you provide any kind of test-case which reproduces the
> problem?
> >
> >
> > Justin
> >
> > [1] https://github.com/apache/activemq-artemis-native
> >
> > On Wed, Feb 19, 2025 at 5:35 AM Franck Malka <fma...@modulo.co.il>
> wrote:
> >
> > > Hi, all
> > >
> > > I have a case with an Artemis ActiveMq cluster which process a very
> large
> > > number of messages per second.
> > >
> > > Each few weeks of operation, JVM memory is still cleaning properly but
> > > native memory is not getting cleared.
> > >
> > > Did anyone encounter this case?
> > > Does it sounds more like a configuration issue? Or like something
> > upgrading
> > > to latest version would address?
> > >
> > > Franck.
> > >
> >
>

Reply via email to