You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by John Lilley <jo...@redpointglobal.com.INVALID> on 2023/01/16 16:30:15 UTC

Messages accumulating in management queue

Greetings!

We are using the Artemis queue-based management APIs, and noticed that one of the two management queues that appears in the console starts to grow without bound:

[cid:image003.png@01D9298D.231470D0]

I don’t know if that image comes through the mailing list, but it shows two of the “activemq.management.<UUID>”  queues, and one of the counts is in the 100s.  It just keeps growing and growing by about 300 per minute.

I’ve tried to browse this queue on the management console, but the browse() operation shows an NPE:
java.lang.NullPointerException : Cannot invoke "org.apache.activemq.artemis.core.paging.cursor.PageSubscription.iterator(boolean)" because "this.this$0.pageSubscription" is null

The calls we are making are like:
String resourceName = ResourceNames.QUEUE + queueName;
ClientRequestor client = getClient();
ClientSession clientSession = …
ClientMessage request = clientSession.createMessage(false);
ManagementHelper.putAttribute(request, resourceName, attributeName);
ClientMessage reply = client.request(request);


Or
ClientRequestor client = getClient();
ClientMessage request = clientSession.createMessage(false);
ManagementHelper.putAttribute(request, resourceName, attributeName);
ClientMessage reply = client.request(request);
if (ManagementHelper.hasOperationSucceeded(reply)) {
       for (var value : (Object[])ManagementHelper.getResult(reply, Object.class)) {
              result.add(value.toString());
       }


Any idea what we are doing wrong?

This happens on windows or linux

Artemis version 2.27.0.

java –version
openjdk 17.0.3 2022-04-19
OpenJDK Runtime Environment Temurin-17.0.3+7 (build 17.0.3+7)
OpenJDK 64-Bit Server VM Temurin-17.0.3+7 (build 17.0.3+7, mixed mode, sharing)

Thanks
john



[rg] <https://www.redpointglobal.com/>

John Lilley

Data Management Chief Architect, Redpoint Global Inc.

888 Worcester Street, Suite 200 Wellesley, MA 02482

M: +1 7209385761<tel:+1%207209385761> | john.lilley@redpointglobal.com<ma...@redpointglobal.com>

PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is confidential and is intended solely for the use of the individual(s) to whom it is addressed. If you believe you received this e-mail in error, please notify the sender immediately, delete the e-mail from your computer and do not copy, print or disclose it to anyone else. If you properly received this e-mail as a customer, partner or vendor of Redpoint, you should maintain its contents in confidence subject to the terms and conditions of your agreement(s) with Redpoint.

Re: Messages accumulating in management queue

Posted by Clebert Suconic <cl...@gmail.com>.
@john for what’s worth I am impressed how Justin himself has been good with
the community.  Thanks and kudos to him  :)


On Tue, Jan 17, 2023 at 3:48 PM John Lilley
<jo...@redpointglobal.com.invalid> wrote:

> Wonderful!  I am really impressed how responsive and active the Artemis
> community is.
>
> john
>
>
>
>
> [image: rg] <https://www.redpointglobal.com/>
>
> John Lilley
>
> Data Management Chief Architect, Redpoint Global Inc.
>
> 888 Worcester Street, Suite 200 Wellesley, MA 02482
> <https://www.google.com/maps/search/888+Worcester+Street,+Suite+200+Wellesley,+MA+02482?entry=gmail&source=g>
>
> *M: *+1 7209385761 <+1%207209385761> | john.lilley@redpointglobal.com
>
> *From:* Justin Bertram <jb...@apache.org>
> *Sent:* Tuesday, January 17, 2023 11:21 AM
> *To:* users@activemq.apache.org
> *Subject:* Re: Messages accumulating in management queue
>
>
>
> **** [Caution] This email is from an external source. Please use caution
> responding, opening attachments or clicking embedded links. ****
>
>
>
> Just to follow up...
>
>
>
> I resolved the NPE you mentioned via ARTEMIS-4135 [1]. That was definitely
> a bug.
>
>
>
>
>
> Justin
>
>
>
> [1] https://issues.apache.org/jira/browse/ARTEMIS-4135
>
>
>
> On Tue, Jan 17, 2023 at 6:50 AM John Lilley <
> john.lilley@redpointglobal.com.invalid> wrote:
>
> Thanks!  That does it.
>
>
>
>
>
> [image: rg]
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,5w1B9g6M4CjsyW6xB7F4YiAcZBiwsYYhr52IujTQ4C77uPG6P7py0vg-wqcGQvLmbidwxECeiKB2JnX_lXF4eN9Phqk8Y8xwYZQ8oQyRxEWj5mA,&typo=1>
>
> *John Lilley *
>
> *Data Management Chief Architect, Redpoint Global Inc. *
>
> 888 Worcester Street, Suite 200 Wellesley, MA 02482
> <https://www.google.com/maps/search/888+Worcester+Street,+Suite+200+Wellesley,+MA+02482?entry=gmail&source=g>
>
> *M: *+1 7209385761 <+1%207209385761> | john.lilley@redpointglobal.com
>
> *From:* Justin Bertram <jb...@apache.org>
> *Sent:* Tuesday, January 17, 2023 12:05 AM
> *To:* users@activemq.apache.org
> *Subject:* Re: Messages accumulating in management queue
>
>
>
> **** [Caution] This email is from an external source. Please use caution
> responding, opening attachments or clicking embedded links. ****
>
>
>
> Thanks for the project. I was able to reproduce the problem and identify
> the root cause of the message accumulation. In short, your application is
> not acknowledging the messages it receives when invoking
> ClientRequestor.request().
>
>
>
> When using the core protocol messages must always be explicitly
> acknowledged. Whether or not those acknowledgements are committed
> automatically depends on how the session is created. In your case you're
> creating a JMS session using the AUTO_ACKNOWLEDGE mode which means the
> underlying core session has autoCommitAcks = true. This isn't obvious since
> you're starting with a JMS implementation object and acquiring the core
> object from it. It would probably be more clear if you just used the core
> API for everything or the JMS API for everything.
>
>
>
> Lastly, if performance really isn't important then it may be simpler to
> eliminate the lock and the object caching and just create the session, etc.
> anytime you need to make a request. Simpler code is easier to write
> initially as well as debug and maintain in the long run. Developer
> productivity is worth a lot so it's worth considering.
>
>
>
>
>
> Justin
>
>
>
> On Mon, Jan 16, 2023 at 11:57 AM John Lilley <
> john.lilley@redpointglobal.com.invalid> wrote:
>
> Justin,
>
>
>
> Link to sample project:
>
>
> https://drive.google.com/file/d/1--vMXNJ3NIUVlRQ9liaMwa-VN3X5uEOE/view?usp=sharing
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fdrive.google.com%2ffile%2fd%2f1--vMXNJ3NIUVlRQ9liaMwa-VN3X5uEOE%2fview%3fusp%3dsharing&c=E,1,93Ca8LeasX6wj9oiXeOQze7DPh66HaLyKmy7noM4bFXLr5AfdYkE4rdHU0qXNhh4dkxNGCBqeBqK6QqlB_6lP8c3ujh2jxPWSaY98TUGAS_peaSm7KmEiCBP&typo=1>
>
>
>
> Any of the three amqUtils.* calls in the main() loop will induce the
> leakage.   I have not figured out where the second queue in our production
> comes from, but that isn’t critical right now.
>
>
>
> Everything serializes through a single lock object, so I don’t think I
> have any thread-safety issues.  Performance is not important.
>
>
>
> Thanks
>
> John
>
>
>
>
>
>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> *John Lilley
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>*
>
> *Data Management Chief Architect, Redpoint Global Inc.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>*
>
> 888 Worcester Street, Suite 200 Wellesley, MA 02482
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> *M: +1 7209385761 | john.lilley@redpointglobal.com
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>*
>
>
>
>
> *From: Justin Bertram <jb...@apache.org> Sent: Monday, January 16, 2023
> 10:31 AM To: users@activemq.apache.org Subject: Re: Messages accumulating
> in management queue
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>*
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> **** [Caution] This email is from an external source. Please use caution
> responding, opening attachments or clicking embedded links. ***
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>*
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> > Is ClientRequestor cheap to make each time?
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> It's relatively cheap, but of course just about anything can be done
> enough to become expensive over time. Also, a ClientRequestor is not
> thread-safe so a single instance may be a bottleneck in your application. I
> don't know what your performance requirements are, how often you're making
> these calls, etc. so it's hard to provide any specific recommendations.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> > One of my colleagues found that occasionally closing and re-creating the
> ClientRequestor avoids this problem, but I’d like to know why.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> I can't rightly say why you're seeing messages build up at this point. The
> screenshot shows that there's a consumer on both queues. Perhaps these
> consumers are no longer acknowledging the messages they receive. You say
> you're only using a single ClientRequestor instance but there's two queues
> which indicates two ClientRequestor instances working concurrently so
> perhaps you're leaking ClientRequestors at some point.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> Do you have a way to reproduce this? If so, could you create a
> reproducible test-case which I could use to see the same behavior?
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> Justin
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> On Mon, Jan 16, 2023 at 10:55 AM John Lilley <
> *john.lilley@redpointglobal.com.invalid*> wrote:
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> We do keep a singleton ClientRequestor around forever.  Perhaps this is
> just wrong?  Is ClientRequestor cheap to make each time?
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> One of my colleagues found that occasionally closing and re-creating the
> ClientRequestor avoids this problem, but I’d like to know why.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> I think you can see that image here:
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> *https://drive.google.com/file/d/1gKDrg4-tRs7WSPbsqQ7Bu-UfhBPu4Fdj/view?usp=sharing*
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> john
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> *John Lilley
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>*
>
> *Data Management Chief Architect, Redpoint Global Inc.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>*
>
> 888 Worcester Street, Suite 200 Wellesley, MA 02482
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> *M: +1 7209385761 | john.lilley@redpointglobal.com
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>*
>
> From: Justin Bertram <*jbertram@apache.org*>
> *Sent:* Monday, January 16, 2023 9:48 AM
> *To:* *users@activemq.apache.org*
> *Subject:* Re: Messages accumulating in management queue
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> **** [Caution] This email is from an external source. Please use caution
> responding, opening attachments or clicking embedded links. ***
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>*
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> > I don’t know if that image comes through the mailing list...
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> I can't see your image. For what it's worth, attachments don't usually
> make it through the list.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> Could you upload the image to another location and provide a link?
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> Also, could you provide the full stack-trace of the NPE?
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> I don't see in your code where you're actually closing the ClientRequestor
> so that might be a problem. Without more details it's impossible to say.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> Justin
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> On Mon, Jan 16, 2023 at 10:31 AM John Lilley <
> *john.lilley@redpointglobal.com.invalid*> wrote:
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> Greetings!
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> We are using the Artemis queue-based management APIs, and noticed that one
> of the two management queues that appears in the console starts to grow
> without bound:
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> I don’t know if that image comes through the mailing list, but it shows
> two of the *xn--activemq-2p3d.management*<UUID>”  queues, and one of the
> counts is in the 100s.  It just keeps growing and growing by about 300 per
> minute.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> I’ve tried to browse this queue on the management console, but the
> browse() operation shows an NPE:
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> java.lang.NullPointerException : Cannot invoke
> "org.apache.activemq.artemis.core.paging.cursor.PageSubscription.iterator(boolean)"
> because "this.this$0.pageSubscription" is null
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> The calls we are making are like:
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> String resourceName = ResourceNames.QUEUE + queueName;
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> ClientRequestor client = getClient();
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> ClientSession clientSession = …
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> ClientMessage request = clientSession.createMessage(false);
> ManagementHelper.putAttribute(request, resourceName, attributeName);
> ClientMessage reply = client.request(request);
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> Or
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> ClientRequestor client = getClient();
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> ClientMessage request = clientSession.createMessage(false);
> ManagementHelper.putAttribute(request, resourceName, attributeName);
> ClientMessage reply = client.request(request);
> if (ManagementHelper.hasOperationSucceeded(reply)) {
>        for (var value : (Object[])ManagementHelper.getResult(reply,
> Object.class)) {
>               result.add(value.toString());
>        }
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> Any idea what we are doing wrong?
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> This happens on windows or linux
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> Artemis version 2.27.0.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> java –version
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> openjdk 17.0.3 2022-04-19
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> OpenJDK Runtime Environment Temurin-17.0.3+7 (build 17.0.3+7)
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> OpenJDK 64-Bit Server VM Temurin-17.0.3+7 (build 17.0.3+7, mixed mode,
> sharing)
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> Thanks
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> john
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> *John Lilley
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>*
>
> *Data Management Chief Architect, Redpoint Global Inc.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>*
>
> 888 Worcester Street, Suite 200 Wellesley, MA 02482
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> *M: +1 7209385761 | john.lilley@redpointglobal.com
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>*
>
>
> PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is
> confidential and is intended solely for the use of the individual(s) to
> whom it is addressed. If you believe you received this e-mail in error,
> please notify the sender immediately, delete the e-mail from your computer
> and do not copy, print or disclose it to anyone else. If you properly
> received this e-mail as a customer, partner or vendor of Redpoint, you
> should maintain its contents in confidence subject to the terms and
> conditions of your agreement(s) with Redpoint.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is
> confidential and is intended solely for the use of the individual(s) to
> whom it is addressed. If you believe you received this e-mail in error,
> please notify the sender immediately, delete the e-mail from your computer
> and do not copy, print or disclose it to anyone else. If you properly
> received this e-mail as a customer, partner or vendor of Redpoint, you
> should maintain its contents in confidence subject to the terms and
> conditions of your agreement(s) with Redpoint.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is
> confidential and is intended solely for the use of the individual(s) to
> whom it is addressed. If you believe you received this e-mail in error,
> please notify the sender immediately, delete the e-mail from your computer
> and do not copy, print or disclose it to anyone else. If you properly
> received this e-mail as a customer, partner or vendor of Redpoint, you
> should maintain its contents in confidence subject to the terms and
> conditions of your agreement(s) with Redpoint.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is
> confidential and is intended solely for the use of the individual(s) to
> whom it is addressed. If you believe you received this e-mail in error,
> please notify the sender immediately, delete the e-mail from your computer
> and do not copy, print or disclose it to anyone else. If you properly
> received this e-mail as a customer, partner or vendor of Redpoint, you
> should maintain its contents in confidence subject to the terms and
> conditions of your agreement(s) with Redpoint.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
>
> PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is
> confidential and is intended solely for the use of the individual(s) to
> whom it is addressed. If you believe you received this e-mail in error,
> please notify the sender immediately, delete the e-mail from your computer
> and do not copy, print or disclose it to anyone else. If you properly
> received this e-mail as a customer, partner or vendor of Redpoint, you
> should maintain its contents in confidence subject to the terms and
> conditions of your agreement(s) with Redpoint.
>
-- 
Clebert Suconic

RE: Messages accumulating in management queue

Posted by John Lilley <jo...@redpointglobal.com.INVALID>.
Wonderful!  I am really impressed how responsive and active the Artemis community is.
john




[rg] <https://www.redpointglobal.com/>

John Lilley

Data Management Chief Architect, Redpoint Global Inc.

888 Worcester Street, Suite 200 Wellesley, MA 02482

M: +1 7209385761<tel:+1%207209385761> | john.lilley@redpointglobal.com<ma...@redpointglobal.com>
From: Justin Bertram <jb...@apache.org>
Sent: Tuesday, January 17, 2023 11:21 AM
To: users@activemq.apache.org
Subject: Re: Messages accumulating in management queue

*** [Caution] This email is from an external source. Please use caution responding, opening attachments or clicking embedded links. ***

Just to follow up...

I resolved the NPE you mentioned via ARTEMIS-4135 [1]. That was definitely a bug.


Justin

[1] https://issues.apache.org/jira/browse/ARTEMIS-4135

On Tue, Jan 17, 2023 at 6:50 AM John Lilley <jo...@redpointglobal.com.invalid>> wrote:
Thanks!  That does it.



[rg]<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,5w1B9g6M4CjsyW6xB7F4YiAcZBiwsYYhr52IujTQ4C77uPG6P7py0vg-wqcGQvLmbidwxECeiKB2JnX_lXF4eN9Phqk8Y8xwYZQ8oQyRxEWj5mA,&typo=1>

John Lilley

Data Management Chief Architect, Redpoint Global Inc.

888 Worcester Street, Suite 200 Wellesley, MA 02482

M: +1 7209385761<tel:+1%207209385761> | john.lilley@redpointglobal.com<ma...@redpointglobal.com>
From: Justin Bertram <jb...@apache.org>>
Sent: Tuesday, January 17, 2023 12:05 AM
To: users@activemq.apache.org<ma...@activemq.apache.org>
Subject: Re: Messages accumulating in management queue

*** [Caution] This email is from an external source. Please use caution responding, opening attachments or clicking embedded links. ***

Thanks for the project. I was able to reproduce the problem and identify the root cause of the message accumulation. In short, your application is not acknowledging the messages it receives when invoking ClientRequestor.request().

When using the core protocol messages must always be explicitly acknowledged. Whether or not those acknowledgements are committed automatically depends on how the session is created. In your case you're creating a JMS session using the AUTO_ACKNOWLEDGE mode which means the underlying core session has autoCommitAcks = true. This isn't obvious since you're starting with a JMS implementation object and acquiring the core object from it. It would probably be more clear if you just used the core API for everything or the JMS API for everything.

Lastly, if performance really isn't important then it may be simpler to eliminate the lock and the object caching and just create the session, etc. anytime you need to make a request. Simpler code is easier to write initially as well as debug and maintain in the long run. Developer productivity is worth a lot so it's worth considering.


Justin

On Mon, Jan 16, 2023 at 11:57 AM John Lilley <jo...@redpointglobal.com.invalid>> wrote:
Justin,

Link to sample project:
https://drive.google.com/file/d/1--vMXNJ3NIUVlRQ9liaMwa-VN3X5uEOE/view?usp=sharing<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fdrive.google.com%2ffile%2fd%2f1--vMXNJ3NIUVlRQ9liaMwa-VN3X5uEOE%2fview%3fusp%3dsharing&c=E,1,93Ca8LeasX6wj9oiXeOQze7DPh66HaLyKmy7noM4bFXLr5AfdYkE4rdHU0qXNhh4dkxNGCBqeBqK6QqlB_6lP8c3ujh2jxPWSaY98TUGAS_peaSm7KmEiCBP&typo=1>

Any of the three amqUtils.* calls in the main() loop will induce the leakage.   I have not figured out where the second queue in our production comes from, but that isn’t critical right now.

Everything serializes through a single lock object, so I don’t think I have any thread-safety issues.  Performance is not important.

Thanks
John




<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

John Lilley <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

Data Management Chief Architect, Redpoint Global Inc. <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

888 Worcester Street, Suite 200 Wellesley, MA 02482 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

M: +1 7209385761 | john.lilley@redpointglobal.com <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
From: Justin Bertram <jb...@apache.org>
Sent: Monday, January 16, 2023 10:31 AM
To: users@activemq.apache.org
Subject: Re: Messages accumulating in management queue<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
*** [Caution] This email is from an external source. Please use caution responding, opening attachments or clicking embedded links. ***<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
> Is ClientRequestor cheap to make each time?<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
It's relatively cheap, but of course just about anything can be done enough to become expensive over time. Also, a ClientRequestor is not thread-safe so a single instance may be a bottleneck in your application. I don't know what your performance requirements are, how often you're making these calls, etc. so it's hard to provide any specific recommendations.<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
> One of my colleagues found that occasionally closing and re-creating the ClientRequestor avoids this problem, but I’d like to know why.<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
I can't rightly say why you're seeing messages build up at this point. The screenshot shows that there's a consumer on both queues. Perhaps these consumers are no longer acknowledging the messages they receive. You say you're only using a single ClientRequestor instance but there's two queues which indicates two ClientRequestor instances working concurrently so perhaps you're leaking ClientRequestors at some point.<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
Do you have a way to reproduce this? If so, could you create a reproducible test-case which I could use to see the same behavior?<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
Justin<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
On Mon, Jan 16, 2023 at 10:55 AM John Lilley <jo...@redpointglobal.com.invalid> wrote:<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
We do keep a singleton ClientRequestor around forever.  Perhaps this is just wrong?  Is ClientRequestor cheap to make each time?<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
One of my colleagues found that occasionally closing and re-creating the ClientRequestor avoids this problem, but I’d like to know why.<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
I think you can see that image here:<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
https://drive.google.com/file/d/1gKDrg4-tRs7WSPbsqQ7Bu-UfhBPu4Fdj/view?usp=sharing<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
john<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

John Lilley <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

Data Management Chief Architect, Redpoint Global Inc. <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

888 Worcester Street, Suite 200 Wellesley, MA 02482 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

M: +1 7209385761 | john.lilley@redpointglobal.com <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
From: Justin Bertram <jb...@apache.org>
Sent: Monday, January 16, 2023 9:48 AM
To: users@activemq.apache.org
Subject: Re: Messages accumulating in management queue<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
*** [Caution] This email is from an external source. Please use caution responding, opening attachments or clicking embedded links. ***<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
> I don’t know if that image comes through the mailing list...<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
I can't see your image. For what it's worth, attachments don't usually make it through the list.<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
Could you upload the image to another location and provide a link?<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
Also, could you provide the full stack-trace of the NPE?<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
I don't see in your code where you're actually closing the ClientRequestor so that might be a problem. Without more details it's impossible to say.<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
Justin<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
On Mon, Jan 16, 2023 at 10:31 AM John Lilley <jo...@redpointglobal.com.invalid> wrote:<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
Greetings!<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
We are using the Artemis queue-based management APIs, and noticed that one of the two management queues that appears in the console starts to grow without bound:<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
I don’t know if that image comes through the mailing list, but it shows two of the xn--activemq-2p3d.management<UUID>”  queues, and one of the counts is in the 100s.  It just keeps growing and growing by about 300 per minute.<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
I’ve tried to browse this queue on the management console, but the browse() operation shows an NPE:<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
java.lang.NullPointerException : Cannot invoke "org.apache.activemq.artemis.core.paging.cursor.PageSubscription.iterator(boolean)" because "this.this$0.pageSubscription" is null<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
The calls we are making are like:<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
String resourceName = ResourceNames.QUEUE + queueName;<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
ClientRequestor client = getClient();<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
ClientSession clientSession = …<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
ClientMessage request = clientSession.createMessage(false);
ManagementHelper.putAttribute(request, resourceName, attributeName);
ClientMessage reply = client.request(request);<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
Or<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
ClientRequestor client = getClient();<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
ClientMessage request = clientSession.createMessage(false);
ManagementHelper.putAttribute(request, resourceName, attributeName);
ClientMessage reply = client.request(request);
if (ManagementHelper.hasOperationSucceeded(reply)) {
       for (var value : (Object[])ManagementHelper.getResult(reply, Object.class)) {
              result.add(value.toString());
       }<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
Any idea what we are doing wrong?<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
This happens on windows or linux<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
Artemis version 2.27.0.<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
java –version<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
openjdk 17.0.3 2022-04-19<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
OpenJDK Runtime Environment Temurin-17.0.3+7 (build 17.0.3+7)<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
OpenJDK 64-Bit Server VM Temurin-17.0.3+7 (build 17.0.3+7, mixed mode, sharing)<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
Thanks<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
john<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

John Lilley <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

Data Management Chief Architect, Redpoint Global Inc. <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

888 Worcester Street, Suite 200 Wellesley, MA 02482 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

M: +1 7209385761 | john.lilley@redpointglobal.com <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is confidential and is intended solely for the use of the individual(s) to whom it is addressed. If you believe you received this e-mail in error, please notify the sender immediately, delete the e-mail from your computer and do not copy, print or disclose it to anyone else. If you properly received this e-mail as a customer, partner or vendor of Redpoint, you should maintain its contents in confidence subject to the terms and conditions of your agreement(s) with Redpoint. <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is confidential and is intended solely for the use of the individual(s) to whom it is addressed. If you believe you received this e-mail in error, please notify the sender immediately, delete the e-mail from your computer and do not copy, print or disclose it to anyone else. If you properly received this e-mail as a customer, partner or vendor of Redpoint, you should maintain its contents in confidence subject to the terms and conditions of your agreement(s) with Redpoint. <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is confidential and is intended solely for the use of the individual(s) to whom it is addressed. If you believe you received this e-mail in error, please notify the sender immediately, delete the e-mail from your computer and do not copy, print or disclose it to anyone else. If you properly received this e-mail as a customer, partner or vendor of Redpoint, you should maintain its contents in confidence subject to the terms and conditions of your agreement(s) with Redpoint. <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is confidential and is intended solely for the use of the individual(s) to whom it is addressed. If you believe you received this e-mail in error, please notify the sender immediately, delete the e-mail from your computer and do not copy, print or disclose it to anyone else. If you properly received this e-mail as a customer, partner or vendor of Redpoint, you should maintain its contents in confidence subject to the terms and conditions of your agreement(s) with Redpoint. <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is confidential and is intended solely for the use of the individual(s) to whom it is addressed. If you believe you received this e-mail in error, please notify the sender immediately, delete the e-mail from your computer and do not copy, print or disclose it to anyone else. If you properly received this e-mail as a customer, partner or vendor of Redpoint, you should maintain its contents in confidence subject to the terms and conditions of your agreement(s) with Redpoint.

Re: Messages accumulating in management queue

Posted by Justin Bertram <jb...@apache.org>.
Just to follow up...

I resolved the NPE you mentioned via ARTEMIS-4135 [1]. That was definitely
a bug.


Justin

[1] https://issues.apache.org/jira/browse/ARTEMIS-4135

On Tue, Jan 17, 2023 at 6:50 AM John Lilley
<jo...@redpointglobal.com.invalid> wrote:

> Thanks!  That does it.
>
>
>
>
> [image: rg] <https://www.redpointglobal.com/>
>
> John Lilley
>
> Data Management Chief Architect, Redpoint Global Inc.
>
> 888 Worcester Street, Suite 200 Wellesley, MA 02482
>
> *M: *+1 7209385761 <+1%207209385761> | john.lilley@redpointglobal.com
>
> *From:* Justin Bertram <jb...@apache.org>
> *Sent:* Tuesday, January 17, 2023 12:05 AM
> *To:* users@activemq.apache.org
> *Subject:* Re: Messages accumulating in management queue
>
>
>
> **** [Caution] This email is from an external source. Please use caution
> responding, opening attachments or clicking embedded links. ****
>
>
>
> Thanks for the project. I was able to reproduce the problem and identify
> the root cause of the message accumulation. In short, your application is
> not acknowledging the messages it receives when invoking
> ClientRequestor.request().
>
>
>
> When using the core protocol messages must always be explicitly
> acknowledged. Whether or not those acknowledgements are committed
> automatically depends on how the session is created. In your case you're
> creating a JMS session using the AUTO_ACKNOWLEDGE mode which means the
> underlying core session has autoCommitAcks = true. This isn't obvious since
> you're starting with a JMS implementation object and acquiring the core
> object from it. It would probably be more clear if you just used the core
> API for everything or the JMS API for everything.
>
>
>
> Lastly, if performance really isn't important then it may be simpler to
> eliminate the lock and the object caching and just create the session, etc.
> anytime you need to make a request. Simpler code is easier to write
> initially as well as debug and maintain in the long run. Developer
> productivity is worth a lot so it's worth considering.
>
>
>
>
>
> Justin
>
>
>
> On Mon, Jan 16, 2023 at 11:57 AM John Lilley <
> john.lilley@redpointglobal.com.invalid> wrote:
>
> Justin,
>
>
>
> Link to sample project:
>
>
> https://drive.google.com/file/d/1--vMXNJ3NIUVlRQ9liaMwa-VN3X5uEOE/view?usp=sharing
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fdrive.google.com%2ffile%2fd%2f1--vMXNJ3NIUVlRQ9liaMwa-VN3X5uEOE%2fview%3fusp%3dsharing&c=E,1,93Ca8LeasX6wj9oiXeOQze7DPh66HaLyKmy7noM4bFXLr5AfdYkE4rdHU0qXNhh4dkxNGCBqeBqK6QqlB_6lP8c3ujh2jxPWSaY98TUGAS_peaSm7KmEiCBP&typo=1>
>
>
>
> Any of the three amqUtils.* calls in the main() loop will induce the
> leakage.   I have not figured out where the second queue in our production
> comes from, but that isn’t critical right now.
>
>
>
> Everything serializes through a single lock object, so I don’t think I
> have any thread-safety issues.  Performance is not important.
>
>
>
> Thanks
>
> John
>
>
>
>
>
>
>
> [image: rg]
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>
>
> *John Lilley *
>
> *Data Management Chief Architect, Redpoint Global Inc. *
>
> 888 Worcester Street, Suite 200 Wellesley, MA 02482
>
> *M: *+1 7209385761 <+1%207209385761> | john.lilley@redpointglobal.com
>
> *From:* Justin Bertram <jb...@apache.org>
> *Sent:* Monday, January 16, 2023 10:31 AM
> *To:* users@activemq.apache.org
> *Subject:* Re: Messages accumulating in management queue
>
>
>
> **** [Caution] This email is from an external source. Please use caution
> responding, opening attachments or clicking embedded links. ****
>
>
>
> > Is ClientRequestor cheap to make each time?
>
>
>
> It's relatively cheap, but of course just about anything can be done
> enough to become expensive over time. Also, a ClientRequestor is not
> thread-safe so a single instance may be a bottleneck in your application. I
> don't know what your performance requirements are, how often you're making
> these calls, etc. so it's hard to provide any specific recommendations.
>
>
>
> > One of my colleagues found that occasionally closing and re-creating the
> ClientRequestor avoids this problem, but I’d like to know why.
>
>
>
> I can't rightly say why you're seeing messages build up at this point. The
> screenshot shows that there's a consumer on both queues. Perhaps these
> consumers are no longer acknowledging the messages they receive. You say
> you're only using a single ClientRequestor instance but there's two queues
> which indicates two ClientRequestor instances working concurrently so
> perhaps you're leaking ClientRequestors at some point.
>
>
>
> Do you have a way to reproduce this? If so, could you create a
> reproducible test-case which I could use to see the same behavior?
>
>
>
>
>
> Justin
>
>
>
> On Mon, Jan 16, 2023 at 10:55 AM John Lilley <
> john.lilley@redpointglobal.com.invalid> wrote:
>
> We do keep a singleton ClientRequestor around forever.  Perhaps this is
> just wrong?  Is ClientRequestor cheap to make each time?
>
>
>
> One of my colleagues found that occasionally closing and re-creating the
> ClientRequestor avoids this problem, but I’d like to know why.
>
>
>
> I think you can see that image here:
>
>
> https://drive.google.com/file/d/1gKDrg4-tRs7WSPbsqQ7Bu-UfhBPu4Fdj/view?usp=sharing
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fdrive.google.com%2ffile%2fd%2f1gKDrg4-tRs7WSPbsqQ7Bu-UfhBPu4Fdj%2fview%3fusp%3dsharing&c=E,1,u7_nPpg3Eo9y9jPflc6RRIEJocNVFDWY6NsGPar5xM7mkglP-pr0VVtdEjUwdkYbOCXZ0Y-5yjk8Kk98uZV7SF4ZpC1xWstZa5vvnWqODa3s&typo=1>
>
>
>
> john
>
>
>
>
>
>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> *John Lilley
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>*
>
> *Data Management Chief Architect, Redpoint Global Inc.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>*
>
> 888 Worcester Street, Suite 200 Wellesley, MA 02482
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> *M: +1 7209385761 | john.lilley@redpointglobal.com
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>*
>
> From: Justin Bertram <*jbertram@apache.org*>
> *Sent:* Monday, January 16, 2023 9:48 AM
> *To:* *users@activemq.apache.org*
> *Subject:* Re: Messages accumulating in management queue
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> **** [Caution] This email is from an external source. Please use caution
> responding, opening attachments or clicking embedded links. ***
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>*
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> > I don’t know if that image comes through the mailing list...
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> I can't see your image. For what it's worth, attachments don't usually
> make it through the list.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> Could you upload the image to another location and provide a link?
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> Also, could you provide the full stack-trace of the NPE?
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> I don't see in your code where you're actually closing the ClientRequestor
> so that might be a problem. Without more details it's impossible to say.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> Justin
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> On Mon, Jan 16, 2023 at 10:31 AM John Lilley <
> *john.lilley@redpointglobal.com.invalid*> wrote:
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> Greetings!
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> We are using the Artemis queue-based management APIs, and noticed that one
> of the two management queues that appears in the console starts to grow
> without bound:
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> I don’t know if that image comes through the mailing list, but it shows
> two of the *xn--activemq-2p3d.management*<UUID>”  queues, and one of the
> counts is in the 100s.  It just keeps growing and growing by about 300 per
> minute.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> I’ve tried to browse this queue on the management console, but the
> browse() operation shows an NPE:
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> java.lang.NullPointerException : Cannot invoke
> "org.apache.activemq.artemis.core.paging.cursor.PageSubscription.iterator(boolean)"
> because "this.this$0.pageSubscription" is null
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> The calls we are making are like:
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> String resourceName = ResourceNames.QUEUE + queueName;
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> ClientRequestor client = getClient();
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> ClientSession clientSession = …
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> ClientMessage request = clientSession.createMessage(false);
> ManagementHelper.putAttribute(request, resourceName, attributeName);
> ClientMessage reply = client.request(request);
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> Or
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> ClientRequestor client = getClient();
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> ClientMessage request = clientSession.createMessage(false);
> ManagementHelper.putAttribute(request, resourceName, attributeName);
> ClientMessage reply = client.request(request);
> if (ManagementHelper.hasOperationSucceeded(reply)) {
>        for (var value : (Object[])ManagementHelper.getResult(reply,
> Object.class)) {
>               result.add(value.toString());
>        }
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> Any idea what we are doing wrong?
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> This happens on windows or linux
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> Artemis version 2.27.0.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> java –version
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> openjdk 17.0.3 2022-04-19
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> OpenJDK Runtime Environment Temurin-17.0.3+7 (build 17.0.3+7)
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> OpenJDK 64-Bit Server VM Temurin-17.0.3+7 (build 17.0.3+7, mixed mode,
> sharing)
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> Thanks
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> john
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> *John Lilley
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>*
>
> *Data Management Chief Architect, Redpoint Global Inc.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>*
>
> 888 Worcester Street, Suite 200 Wellesley, MA 02482
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> *M: +1 7209385761 | john.lilley@redpointglobal.com
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>*
>
>
> PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is
> confidential and is intended solely for the use of the individual(s) to
> whom it is addressed. If you believe you received this e-mail in error,
> please notify the sender immediately, delete the e-mail from your computer
> and do not copy, print or disclose it to anyone else. If you properly
> received this e-mail as a customer, partner or vendor of Redpoint, you
> should maintain its contents in confidence subject to the terms and
> conditions of your agreement(s) with Redpoint.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is
> confidential and is intended solely for the use of the individual(s) to
> whom it is addressed. If you believe you received this e-mail in error,
> please notify the sender immediately, delete the e-mail from your computer
> and do not copy, print or disclose it to anyone else. If you properly
> received this e-mail as a customer, partner or vendor of Redpoint, you
> should maintain its contents in confidence subject to the terms and
> conditions of your agreement(s) with Redpoint.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is
> confidential and is intended solely for the use of the individual(s) to
> whom it is addressed. If you believe you received this e-mail in error,
> please notify the sender immediately, delete the e-mail from your computer
> and do not copy, print or disclose it to anyone else. If you properly
> received this e-mail as a customer, partner or vendor of Redpoint, you
> should maintain its contents in confidence subject to the terms and
> conditions of your agreement(s) with Redpoint.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
>
> PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is
> confidential and is intended solely for the use of the individual(s) to
> whom it is addressed. If you believe you received this e-mail in error,
> please notify the sender immediately, delete the e-mail from your computer
> and do not copy, print or disclose it to anyone else. If you properly
> received this e-mail as a customer, partner or vendor of Redpoint, you
> should maintain its contents in confidence subject to the terms and
> conditions of your agreement(s) with Redpoint.
>

RE: Messages accumulating in management queue

Posted by John Lilley <jo...@redpointglobal.com.INVALID>.
Thanks!  That does it.




[rg] <https://www.redpointglobal.com/>

John Lilley

Data Management Chief Architect, Redpoint Global Inc.

888 Worcester Street, Suite 200 Wellesley, MA 02482

M: +1 7209385761<tel:+1%207209385761> | john.lilley@redpointglobal.com<ma...@redpointglobal.com>
From: Justin Bertram <jb...@apache.org>
Sent: Tuesday, January 17, 2023 12:05 AM
To: users@activemq.apache.org
Subject: Re: Messages accumulating in management queue

*** [Caution] This email is from an external source. Please use caution responding, opening attachments or clicking embedded links. ***

Thanks for the project. I was able to reproduce the problem and identify the root cause of the message accumulation. In short, your application is not acknowledging the messages it receives when invoking ClientRequestor.request().

When using the core protocol messages must always be explicitly acknowledged. Whether or not those acknowledgements are committed automatically depends on how the session is created. In your case you're creating a JMS session using the AUTO_ACKNOWLEDGE mode which means the underlying core session has autoCommitAcks = true. This isn't obvious since you're starting with a JMS implementation object and acquiring the core object from it. It would probably be more clear if you just used the core API for everything or the JMS API for everything.

Lastly, if performance really isn't important then it may be simpler to eliminate the lock and the object caching and just create the session, etc. anytime you need to make a request. Simpler code is easier to write initially as well as debug and maintain in the long run. Developer productivity is worth a lot so it's worth considering.


Justin

On Mon, Jan 16, 2023 at 11:57 AM John Lilley <jo...@redpointglobal.com.invalid>> wrote:
Justin,

Link to sample project:
https://drive.google.com/file/d/1--vMXNJ3NIUVlRQ9liaMwa-VN3X5uEOE/view?usp=sharing<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fdrive.google.com%2ffile%2fd%2f1--vMXNJ3NIUVlRQ9liaMwa-VN3X5uEOE%2fview%3fusp%3dsharing&c=E,1,93Ca8LeasX6wj9oiXeOQze7DPh66HaLyKmy7noM4bFXLr5AfdYkE4rdHU0qXNhh4dkxNGCBqeBqK6QqlB_6lP8c3ujh2jxPWSaY98TUGAS_peaSm7KmEiCBP&typo=1>

Any of the three amqUtils.* calls in the main() loop will induce the leakage.   I have not figured out where the second queue in our production comes from, but that isn’t critical right now.

Everything serializes through a single lock object, so I don’t think I have any thread-safety issues.  Performance is not important.

Thanks
John




[rg]<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,z4UyUbdX11BxHjFJuvWWUL0Oixo57hoHITvAAEdJhCZyZRIaeKd493bkZjsuhVxkKMxCMiMa22mLQn3pZu5R7L_-UCsQAi-nHqjrD765Nd1UzQ,,&typo=1>

John Lilley

Data Management Chief Architect, Redpoint Global Inc.

888 Worcester Street, Suite 200 Wellesley, MA 02482

M: +1 7209385761<tel:+1%207209385761> | john.lilley@redpointglobal.com<ma...@redpointglobal.com>
From: Justin Bertram <jb...@apache.org>>
Sent: Monday, January 16, 2023 10:31 AM
To: users@activemq.apache.org<ma...@activemq.apache.org>
Subject: Re: Messages accumulating in management queue

*** [Caution] This email is from an external source. Please use caution responding, opening attachments or clicking embedded links. ***

> Is ClientRequestor cheap to make each time?

It's relatively cheap, but of course just about anything can be done enough to become expensive over time. Also, a ClientRequestor is not thread-safe so a single instance may be a bottleneck in your application. I don't know what your performance requirements are, how often you're making these calls, etc. so it's hard to provide any specific recommendations.

> One of my colleagues found that occasionally closing and re-creating the ClientRequestor avoids this problem, but I’d like to know why.

I can't rightly say why you're seeing messages build up at this point. The screenshot shows that there's a consumer on both queues. Perhaps these consumers are no longer acknowledging the messages they receive. You say you're only using a single ClientRequestor instance but there's two queues which indicates two ClientRequestor instances working concurrently so perhaps you're leaking ClientRequestors at some point.

Do you have a way to reproduce this? If so, could you create a reproducible test-case which I could use to see the same behavior?


Justin

On Mon, Jan 16, 2023 at 10:55 AM John Lilley <jo...@redpointglobal.com.invalid>> wrote:
We do keep a singleton ClientRequestor around forever.  Perhaps this is just wrong?  Is ClientRequestor cheap to make each time?

One of my colleagues found that occasionally closing and re-creating the ClientRequestor avoids this problem, but I’d like to know why.

I think you can see that image here:
https://drive.google.com/file/d/1gKDrg4-tRs7WSPbsqQ7Bu-UfhBPu4Fdj/view?usp=sharing<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fdrive.google.com%2ffile%2fd%2f1gKDrg4-tRs7WSPbsqQ7Bu-UfhBPu4Fdj%2fview%3fusp%3dsharing&c=E,1,u7_nPpg3Eo9y9jPflc6RRIEJocNVFDWY6NsGPar5xM7mkglP-pr0VVtdEjUwdkYbOCXZ0Y-5yjk8Kk98uZV7SF4ZpC1xWstZa5vvnWqODa3s&typo=1>

john




<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>

John Lilley <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>

Data Management Chief Architect, Redpoint Global Inc. <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>

888 Worcester Street, Suite 200 Wellesley, MA 02482 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>

M: +1 7209385761 | john.lilley@redpointglobal.com <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
From: Justin Bertram <jb...@apache.org>
Sent: Monday, January 16, 2023 9:48 AM
To: users@activemq.apache.org
Subject: Re: Messages accumulating in management queue<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
*** [Caution] This email is from an external source. Please use caution responding, opening attachments or clicking embedded links. ***<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
> I don’t know if that image comes through the mailing list...<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
I can't see your image. For what it's worth, attachments don't usually make it through the list.<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
Could you upload the image to another location and provide a link?<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
Also, could you provide the full stack-trace of the NPE?<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
I don't see in your code where you're actually closing the ClientRequestor so that might be a problem. Without more details it's impossible to say.<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
Justin<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
On Mon, Jan 16, 2023 at 10:31 AM John Lilley <jo...@redpointglobal.com.invalid> wrote:<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
Greetings!<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
We are using the Artemis queue-based management APIs, and noticed that one of the two management queues that appears in the console starts to grow without bound:<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
I don’t know if that image comes through the mailing list, but it shows two of the xn--activemq-2p3d.management<UUID>”  queues, and one of the counts is in the 100s.  It just keeps growing and growing by about 300 per minute.<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
I’ve tried to browse this queue on the management console, but the browse() operation shows an NPE:<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
java.lang.NullPointerException : Cannot invoke "org.apache.activemq.artemis.core.paging.cursor.PageSubscription.iterator(boolean)" because "this.this$0.pageSubscription" is null<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
The calls we are making are like:<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
String resourceName = ResourceNames.QUEUE + queueName;<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
ClientRequestor client = getClient();<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
ClientSession clientSession = …<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
ClientMessage request = clientSession.createMessage(false);
ManagementHelper.putAttribute(request, resourceName, attributeName);
ClientMessage reply = client.request(request);<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
Or<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
ClientRequestor client = getClient();<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
ClientMessage request = clientSession.createMessage(false);
ManagementHelper.putAttribute(request, resourceName, attributeName);
ClientMessage reply = client.request(request);
if (ManagementHelper.hasOperationSucceeded(reply)) {
       for (var value : (Object[])ManagementHelper.getResult(reply, Object.class)) {
              result.add(value.toString());
       }<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
Any idea what we are doing wrong?<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
This happens on windows or linux<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
Artemis version 2.27.0.<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
java –version<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
openjdk 17.0.3 2022-04-19<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
OpenJDK Runtime Environment Temurin-17.0.3+7 (build 17.0.3+7)<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
OpenJDK 64-Bit Server VM Temurin-17.0.3+7 (build 17.0.3+7, mixed mode, sharing)<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
Thanks<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
john<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>

John Lilley <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>

Data Management Chief Architect, Redpoint Global Inc. <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>

888 Worcester Street, Suite 200 Wellesley, MA 02482 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>

M: +1 7209385761 | john.lilley@redpointglobal.com <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>

PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is confidential and is intended solely for the use of the individual(s) to whom it is addressed. If you believe you received this e-mail in error, please notify the sender immediately, delete the e-mail from your computer and do not copy, print or disclose it to anyone else. If you properly received this e-mail as a customer, partner or vendor of Redpoint, you should maintain its contents in confidence subject to the terms and conditions of your agreement(s) with Redpoint. <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>

PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is confidential and is intended solely for the use of the individual(s) to whom it is addressed. If you believe you received this e-mail in error, please notify the sender immediately, delete the e-mail from your computer and do not copy, print or disclose it to anyone else. If you properly received this e-mail as a customer, partner or vendor of Redpoint, you should maintain its contents in confidence subject to the terms and conditions of your agreement(s) with Redpoint. <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>

PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is confidential and is intended solely for the use of the individual(s) to whom it is addressed. If you believe you received this e-mail in error, please notify the sender immediately, delete the e-mail from your computer and do not copy, print or disclose it to anyone else. If you properly received this e-mail as a customer, partner or vendor of Redpoint, you should maintain its contents in confidence subject to the terms and conditions of your agreement(s) with Redpoint. <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>

PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is confidential and is intended solely for the use of the individual(s) to whom it is addressed. If you believe you received this e-mail in error, please notify the sender immediately, delete the e-mail from your computer and do not copy, print or disclose it to anyone else. If you properly received this e-mail as a customer, partner or vendor of Redpoint, you should maintain its contents in confidence subject to the terms and conditions of your agreement(s) with Redpoint.

Re: Messages accumulating in management queue

Posted by Justin Bertram <jb...@apache.org>.
Thanks for the project. I was able to reproduce the problem and identify
the root cause of the message accumulation. In short, your application is
not acknowledging the messages it receives when invoking
ClientRequestor.request().

When using the core protocol messages must always be explicitly
acknowledged. Whether or not those acknowledgements are committed
automatically depends on how the session is created. In your case you're
creating a JMS session using the AUTO_ACKNOWLEDGE mode which means the
underlying core session has autoCommitAcks = true. This isn't obvious since
you're starting with a JMS implementation object and acquiring the core
object from it. It would probably be more clear if you just used the core
API for everything or the JMS API for everything.

Lastly, if performance really isn't important then it may be simpler to
eliminate the lock and the object caching and just create the session, etc.
anytime you need to make a request. Simpler code is easier to write
initially as well as debug and maintain in the long run. Developer
productivity is worth a lot so it's worth considering.


Justin

On Mon, Jan 16, 2023 at 11:57 AM John Lilley
<jo...@redpointglobal.com.invalid> wrote:

> Justin,
>
>
>
> Link to sample project:
>
>
> https://drive.google.com/file/d/1--vMXNJ3NIUVlRQ9liaMwa-VN3X5uEOE/view?usp=sharing
>
>
>
> Any of the three amqUtils.* calls in the main() loop will induce the
> leakage.   I have not figured out where the second queue in our production
> comes from, but that isn’t critical right now.
>
>
>
> Everything serializes through a single lock object, so I don’t think I
> have any thread-safety issues.  Performance is not important.
>
>
>
> Thanks
>
> John
>
>
>
>
>
>
> [image: rg] <https://www.redpointglobal.com/>
>
> John Lilley
>
> Data Management Chief Architect, Redpoint Global Inc.
>
> 888 Worcester Street, Suite 200 Wellesley, MA 02482
>
> *M: *+1 7209385761 <+1%207209385761> | john.lilley@redpointglobal.com
>
> *From:* Justin Bertram <jb...@apache.org>
> *Sent:* Monday, January 16, 2023 10:31 AM
> *To:* users@activemq.apache.org
> *Subject:* Re: Messages accumulating in management queue
>
>
>
> **** [Caution] This email is from an external source. Please use caution
> responding, opening attachments or clicking embedded links. ****
>
>
>
> > Is ClientRequestor cheap to make each time?
>
>
>
> It's relatively cheap, but of course just about anything can be done
> enough to become expensive over time. Also, a ClientRequestor is not
> thread-safe so a single instance may be a bottleneck in your application. I
> don't know what your performance requirements are, how often you're making
> these calls, etc. so it's hard to provide any specific recommendations.
>
>
>
> > One of my colleagues found that occasionally closing and re-creating the
> ClientRequestor avoids this problem, but I’d like to know why.
>
>
>
> I can't rightly say why you're seeing messages build up at this point. The
> screenshot shows that there's a consumer on both queues. Perhaps these
> consumers are no longer acknowledging the messages they receive. You say
> you're only using a single ClientRequestor instance but there's two queues
> which indicates two ClientRequestor instances working concurrently so
> perhaps you're leaking ClientRequestors at some point.
>
>
>
> Do you have a way to reproduce this? If so, could you create a
> reproducible test-case which I could use to see the same behavior?
>
>
>
>
>
> Justin
>
>
>
> On Mon, Jan 16, 2023 at 10:55 AM John Lilley <
> john.lilley@redpointglobal.com.invalid> wrote:
>
> We do keep a singleton ClientRequestor around forever.  Perhaps this is
> just wrong?  Is ClientRequestor cheap to make each time?
>
>
>
> One of my colleagues found that occasionally closing and re-creating the
> ClientRequestor avoids this problem, but I’d like to know why.
>
>
>
> I think you can see that image here:
>
>
> https://drive.google.com/file/d/1gKDrg4-tRs7WSPbsqQ7Bu-UfhBPu4Fdj/view?usp=sharing
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fdrive.google.com%2ffile%2fd%2f1gKDrg4-tRs7WSPbsqQ7Bu-UfhBPu4Fdj%2fview%3fusp%3dsharing&c=E,1,u7_nPpg3Eo9y9jPflc6RRIEJocNVFDWY6NsGPar5xM7mkglP-pr0VVtdEjUwdkYbOCXZ0Y-5yjk8Kk98uZV7SF4ZpC1xWstZa5vvnWqODa3s&typo=1>
>
>
>
> john
>
>
>
>
>
>
>
> [image: rg]
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>
>
> *John Lilley *
>
> *Data Management Chief Architect, Redpoint Global Inc. *
>
> 888 Worcester Street, Suite 200 Wellesley, MA 02482
>
> *M: *+1 7209385761 <+1%207209385761> | john.lilley@redpointglobal.com
>
> From: Justin Bertram <jb...@apache.org>
> *Sent:* Monday, January 16, 2023 9:48 AM
> *To:* users@activemq.apache.org
> *Subject:* Re: Messages accumulating in management queue
>
>
>
> **** [Caution] This email is from an external source. Please use caution
> responding, opening attachments or clicking embedded links. ****
>
>
>
> > I don’t know if that image comes through the mailing list...
>
>
>
> I can't see your image. For what it's worth, attachments don't usually
> make it through the list.
>
>
>
> Could you upload the image to another location and provide a link?
>
>
>
> Also, could you provide the full stack-trace of the NPE?
>
>
>
> I don't see in your code where you're actually closing the ClientRequestor
> so that might be a problem. Without more details it's impossible to say.
>
>
>
>
>
> Justin
>
>
>
> On Mon, Jan 16, 2023 at 10:31 AM John Lilley <
> john.lilley@redpointglobal.com.invalid> wrote:
>
> Greetings!
>
>
>
> We are using the Artemis queue-based management APIs, and noticed that one
> of the two management queues that appears in the console starts to grow
> without bound:
>
>
>
>
>
> I don’t know if that image comes through the mailing list, but it shows
> two of the xn--activemq-2p3d.management
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fxn--activemq-2p3d.management&c=E,1,yM5VuqjniGEfl7K4rM70Xa-2jC5pkpu2WMCuv2o_9ssgUAyqDzgAfPDtdn-xMCHxrbyaUxPnF2oUZkGoCF_o-vv_o42p3PRnI9YguDv7nT8RO5syVzebSQ,,&typo=1&ancr_add=1><UUID>”
>  queues, and one of the counts is in the 100s.  It just keeps growing and
> growing by about 300 per minute.
>
>
>
> I’ve tried to browse this queue on the management console, but the
> browse() operation shows an NPE:
>
> java.lang.NullPointerException : Cannot invoke
> "org.apache.activemq.artemis.core.paging.cursor.PageSubscription.iterator(boolean)"
> because "this.this$0.pageSubscription" is null
>
>
>
> The calls we are making are like:
>
> String resourceName = ResourceNames.QUEUE + queueName;
>
> ClientRequestor client = getClient();
>
> ClientSession clientSession = …
>
> ClientMessage request = clientSession.createMessage(false);
> ManagementHelper.putAttribute(request, resourceName, attributeName);
> ClientMessage reply = client.request(request);
>
>
>
> Or
>
> ClientRequestor client = getClient();
>
> ClientMessage request = clientSession.createMessage(false);
> ManagementHelper.putAttribute(request, resourceName, attributeName);
> ClientMessage reply = client.request(request);
> if (ManagementHelper.hasOperationSucceeded(reply)) {
>        for (var value : (Object[])ManagementHelper.getResult(reply,
> Object.class)) {
>               result.add(value.toString());
>        }
>
>
>
> Any idea what we are doing wrong?
>
>
>
> This happens on windows or linux
>
>
>
> Artemis version 2.27.0.
>
>
>
> java –version
>
> openjdk 17.0.3 2022-04-19
>
> OpenJDK Runtime Environment Temurin-17.0.3+7 (build 17.0.3+7)
>
> OpenJDK 64-Bit Server VM Temurin-17.0.3+7 (build 17.0.3+7, mixed mode,
> sharing)
>
>
>
> Thanks
>
> john
>
>
>
>
>
>
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>
>
> *John Lilley
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>*
>
> *Data Management Chief Architect, Redpoint Global Inc.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>*
>
> 888 Worcester Street, Suite 200 Wellesley, MA 02482
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>
>
> *M: +1 7209385761 | john.lilley@redpointglobal.com
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>*
>
>
> PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is
> confidential and is intended solely for the use of the individual(s) to
> whom it is addressed. If you believe you received this e-mail in error,
> please notify the sender immediately, delete the e-mail from your computer
> and do not copy, print or disclose it to anyone else. If you properly
> received this e-mail as a customer, partner or vendor of Redpoint, you
> should maintain its contents in confidence subject to the terms and
> conditions of your agreement(s) with Redpoint.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>
>
>
> PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is
> confidential and is intended solely for the use of the individual(s) to
> whom it is addressed. If you believe you received this e-mail in error,
> please notify the sender immediately, delete the e-mail from your computer
> and do not copy, print or disclose it to anyone else. If you properly
> received this e-mail as a customer, partner or vendor of Redpoint, you
> should maintain its contents in confidence subject to the terms and
> conditions of your agreement(s) with Redpoint.
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>
>
>
> PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is
> confidential and is intended solely for the use of the individual(s) to
> whom it is addressed. If you believe you received this e-mail in error,
> please notify the sender immediately, delete the e-mail from your computer
> and do not copy, print or disclose it to anyone else. If you properly
> received this e-mail as a customer, partner or vendor of Redpoint, you
> should maintain its contents in confidence subject to the terms and
> conditions of your agreement(s) with Redpoint.
>

RE: Messages accumulating in management queue

Posted by John Lilley <jo...@redpointglobal.com.INVALID>.
Justin,

Link to sample project:
https://drive.google.com/file/d/1--vMXNJ3NIUVlRQ9liaMwa-VN3X5uEOE/view?usp=sharing

Any of the three amqUtils.* calls in the main() loop will induce the leakage.   I have not figured out where the second queue in our production comes from, but that isn’t critical right now.

Everything serializes through a single lock object, so I don’t think I have any thread-safety issues.  Performance is not important.

Thanks
John





[rg] <https://www.redpointglobal.com/>

John Lilley

Data Management Chief Architect, Redpoint Global Inc.

888 Worcester Street, Suite 200 Wellesley, MA 02482

M: +1 7209385761<tel:+1%207209385761> | john.lilley@redpointglobal.com<ma...@redpointglobal.com>
From: Justin Bertram <jb...@apache.org>
Sent: Monday, January 16, 2023 10:31 AM
To: users@activemq.apache.org
Subject: Re: Messages accumulating in management queue

*** [Caution] This email is from an external source. Please use caution responding, opening attachments or clicking embedded links. ***

> Is ClientRequestor cheap to make each time?

It's relatively cheap, but of course just about anything can be done enough to become expensive over time. Also, a ClientRequestor is not thread-safe so a single instance may be a bottleneck in your application. I don't know what your performance requirements are, how often you're making these calls, etc. so it's hard to provide any specific recommendations.

> One of my colleagues found that occasionally closing and re-creating the ClientRequestor avoids this problem, but I’d like to know why.

I can't rightly say why you're seeing messages build up at this point. The screenshot shows that there's a consumer on both queues. Perhaps these consumers are no longer acknowledging the messages they receive. You say you're only using a single ClientRequestor instance but there's two queues which indicates two ClientRequestor instances working concurrently so perhaps you're leaking ClientRequestors at some point.

Do you have a way to reproduce this? If so, could you create a reproducible test-case which I could use to see the same behavior?


Justin

On Mon, Jan 16, 2023 at 10:55 AM John Lilley <jo...@redpointglobal.com.invalid>> wrote:
We do keep a singleton ClientRequestor around forever.  Perhaps this is just wrong?  Is ClientRequestor cheap to make each time?

One of my colleagues found that occasionally closing and re-creating the ClientRequestor avoids this problem, but I’d like to know why.

I think you can see that image here:
https://drive.google.com/file/d/1gKDrg4-tRs7WSPbsqQ7Bu-UfhBPu4Fdj/view?usp=sharing<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fdrive.google.com%2ffile%2fd%2f1gKDrg4-tRs7WSPbsqQ7Bu-UfhBPu4Fdj%2fview%3fusp%3dsharing&c=E,1,u7_nPpg3Eo9y9jPflc6RRIEJocNVFDWY6NsGPar5xM7mkglP-pr0VVtdEjUwdkYbOCXZ0Y-5yjk8Kk98uZV7SF4ZpC1xWstZa5vvnWqODa3s&typo=1>

john




[rg]<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,vfQKtAcb52qTSJksDEbpSPPMH35oLMHbFHh03U5Yjymdi6_74sLsjOSkxSqYP1iE7FxcrLU9BjLO5yYbNQBwawQCxa6TY2UFcPEWp1xShdsR&typo=1>

John Lilley

Data Management Chief Architect, Redpoint Global Inc.

888 Worcester Street, Suite 200 Wellesley, MA 02482

M: +1 7209385761<tel:+1%207209385761> | john.lilley@redpointglobal.com<ma...@redpointglobal.com>
From: Justin Bertram <jb...@apache.org>>
Sent: Monday, January 16, 2023 9:48 AM
To: users@activemq.apache.org<ma...@activemq.apache.org>
Subject: Re: Messages accumulating in management queue

*** [Caution] This email is from an external source. Please use caution responding, opening attachments or clicking embedded links. ***

> I don’t know if that image comes through the mailing list...

I can't see your image. For what it's worth, attachments don't usually make it through the list.

Could you upload the image to another location and provide a link?

Also, could you provide the full stack-trace of the NPE?

I don't see in your code where you're actually closing the ClientRequestor so that might be a problem. Without more details it's impossible to say.


Justin

On Mon, Jan 16, 2023 at 10:31 AM John Lilley <jo...@redpointglobal.com.invalid>> wrote:
Greetings!

We are using the Artemis queue-based management APIs, and noticed that one of the two management queues that appears in the console starts to grow without bound:


I don’t know if that image comes through the mailing list, but it shows two of the xn--activemq-2p3d.management<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fxn--activemq-2p3d.management&c=E,1,yM5VuqjniGEfl7K4rM70Xa-2jC5pkpu2WMCuv2o_9ssgUAyqDzgAfPDtdn-xMCHxrbyaUxPnF2oUZkGoCF_o-vv_o42p3PRnI9YguDv7nT8RO5syVzebSQ,,&typo=1&ancr_add=1><UUID>”  queues, and one of the counts is in the 100s.  It just keeps growing and growing by about 300 per minute.

I’ve tried to browse this queue on the management console, but the browse() operation shows an NPE:
java.lang.NullPointerException : Cannot invoke "org.apache.activemq.artemis.core.paging.cursor.PageSubscription.iterator(boolean)" because "this.this$0.pageSubscription" is null

The calls we are making are like:
String resourceName = ResourceNames.QUEUE + queueName;
ClientRequestor client = getClient();
ClientSession clientSession = …
ClientMessage request = clientSession.createMessage(false);
ManagementHelper.putAttribute(request, resourceName, attributeName);
ClientMessage reply = client.request(request);

Or
ClientRequestor client = getClient();
ClientMessage request = clientSession.createMessage(false);
ManagementHelper.putAttribute(request, resourceName, attributeName);
ClientMessage reply = client.request(request);
if (ManagementHelper.hasOperationSucceeded(reply)) {
       for (var value : (Object[])ManagementHelper.getResult(reply, Object.class)) {
              result.add(value.toString());
       }

Any idea what we are doing wrong?

This happens on windows or linux

Artemis version 2.27.0.

java –version
openjdk 17.0.3 2022-04-19
OpenJDK Runtime Environment Temurin-17.0.3+7 (build 17.0.3+7)
OpenJDK 64-Bit Server VM Temurin-17.0.3+7 (build 17.0.3+7, mixed mode, sharing)

Thanks
john



<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>

John Lilley <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>

Data Management Chief Architect, Redpoint Global Inc. <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>

888 Worcester Street, Suite 200 Wellesley, MA 02482 <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>

M: +1 7209385761 | john.lilley@redpointglobal.com <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>

PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is confidential and is intended solely for the use of the individual(s) to whom it is addressed. If you believe you received this e-mail in error, please notify the sender immediately, delete the e-mail from your computer and do not copy, print or disclose it to anyone else. If you properly received this e-mail as a customer, partner or vendor of Redpoint, you should maintain its contents in confidence subject to the terms and conditions of your agreement(s) with Redpoint. <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>

PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is confidential and is intended solely for the use of the individual(s) to whom it is addressed. If you believe you received this e-mail in error, please notify the sender immediately, delete the e-mail from your computer and do not copy, print or disclose it to anyone else. If you properly received this e-mail as a customer, partner or vendor of Redpoint, you should maintain its contents in confidence subject to the terms and conditions of your agreement(s) with Redpoint. <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>

PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is confidential and is intended solely for the use of the individual(s) to whom it is addressed. If you believe you received this e-mail in error, please notify the sender immediately, delete the e-mail from your computer and do not copy, print or disclose it to anyone else. If you properly received this e-mail as a customer, partner or vendor of Redpoint, you should maintain its contents in confidence subject to the terms and conditions of your agreement(s) with Redpoint.

Re: Messages accumulating in management queue

Posted by Justin Bertram <jb...@apache.org>.
> Is ClientRequestor cheap to make each time?

It's relatively cheap, but of course just about anything can be done enough
to become expensive over time. Also, a ClientRequestor is not thread-safe
so a single instance may be a bottleneck in your application. I don't know
what your performance requirements are, how often you're making these
calls, etc. so it's hard to provide any specific recommendations.

> One of my colleagues found that occasionally closing and re-creating the
ClientRequestor avoids this problem, but I’d like to know why.

I can't rightly say why you're seeing messages build up at this point. The
screenshot shows that there's a consumer on both queues. Perhaps these
consumers are no longer acknowledging the messages they receive. You say
you're only using a single ClientRequestor instance but there's two queues
which indicates two ClientRequestor instances working concurrently so
perhaps you're leaking ClientRequestors at some point.

Do you have a way to reproduce this? If so, could you create a reproducible
test-case which I could use to see the same behavior?


Justin

On Mon, Jan 16, 2023 at 10:55 AM John Lilley
<jo...@redpointglobal.com.invalid> wrote:

> We do keep a singleton ClientRequestor around forever.  Perhaps this is
> just wrong?  Is ClientRequestor cheap to make each time?
>
>
>
> One of my colleagues found that occasionally closing and re-creating the
> ClientRequestor avoids this problem, but I’d like to know why.
>
>
>
> I think you can see that image here:
>
>
> https://drive.google.com/file/d/1gKDrg4-tRs7WSPbsqQ7Bu-UfhBPu4Fdj/view?usp=sharing
>
>
>
> john
>
>
>
>
>
>
> [image: rg] <https://www.redpointglobal.com/>
>
> John Lilley
>
> Data Management Chief Architect, Redpoint Global Inc.
>
> 888 Worcester Street, Suite 200 Wellesley, MA 02482
>
> *M: *+1 7209385761 <+1%207209385761> | john.lilley@redpointglobal.com
>
> From: Justin Bertram <jb...@apache.org>
> *Sent:* Monday, January 16, 2023 9:48 AM
> *To:* users@activemq.apache.org
> *Subject:* Re: Messages accumulating in management queue
>
>
>
> **** [Caution] This email is from an external source. Please use caution
> responding, opening attachments or clicking embedded links. ****
>
>
>
> > I don’t know if that image comes through the mailing list...
>
>
>
> I can't see your image. For what it's worth, attachments don't usually
> make it through the list.
>
>
>
> Could you upload the image to another location and provide a link?
>
>
>
> Also, could you provide the full stack-trace of the NPE?
>
>
>
> I don't see in your code where you're actually closing the ClientRequestor
> so that might be a problem. Without more details it's impossible to say.
>
>
>
>
>
> Justin
>
>
>
> On Mon, Jan 16, 2023 at 10:31 AM John Lilley <
> john.lilley@redpointglobal.com.invalid> wrote:
>
> Greetings!
>
>
>
> We are using the Artemis queue-based management APIs, and noticed that one
> of the two management queues that appears in the console starts to grow
> without bound:
>
>
>
>
>
> I don’t know if that image comes through the mailing list, but it shows
> two of the xn--activemq-2p3d.management
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fxn--activemq-2p3d.management&c=E,1,yM5VuqjniGEfl7K4rM70Xa-2jC5pkpu2WMCuv2o_9ssgUAyqDzgAfPDtdn-xMCHxrbyaUxPnF2oUZkGoCF_o-vv_o42p3PRnI9YguDv7nT8RO5syVzebSQ,,&typo=1&ancr_add=1><UUID>”
>  queues, and one of the counts is in the 100s.  It just keeps growing and
> growing by about 300 per minute.
>
>
>
> I’ve tried to browse this queue on the management console, but the
> browse() operation shows an NPE:
>
> java.lang.NullPointerException : Cannot invoke
> "org.apache.activemq.artemis.core.paging.cursor.PageSubscription.iterator(boolean)"
> because "this.this$0.pageSubscription" is null
>
>
>
> The calls we are making are like:
>
> String resourceName = ResourceNames.QUEUE + queueName;
>
> ClientRequestor client = getClient();
>
> ClientSession clientSession = …
>
> ClientMessage request = clientSession.createMessage(false);
> ManagementHelper.putAttribute(request, resourceName, attributeName);
> ClientMessage reply = client.request(request);
>
>
>
> Or
>
> ClientRequestor client = getClient();
>
> ClientMessage request = clientSession.createMessage(false);
> ManagementHelper.putAttribute(request, resourceName, attributeName);
> ClientMessage reply = client.request(request);
> if (ManagementHelper.hasOperationSucceeded(reply)) {
>        for (var value : (Object[])ManagementHelper.getResult(reply,
> Object.class)) {
>               result.add(value.toString());
>        }
>
>
>
> Any idea what we are doing wrong?
>
>
>
> This happens on windows or linux
>
>
>
> Artemis version 2.27.0.
>
>
>
> java –version
>
> openjdk 17.0.3 2022-04-19
>
> OpenJDK Runtime Environment Temurin-17.0.3+7 (build 17.0.3+7)
>
> OpenJDK 64-Bit Server VM Temurin-17.0.3+7 (build 17.0.3+7, mixed mode,
> sharing)
>
>
>
> Thanks
>
> john
>
>
>
>
>
> [image: rg]
> <https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>
>
> *John Lilley *
>
> *Data Management Chief Architect, Redpoint Global Inc. *
>
> 888 Worcester Street, Suite 200 Wellesley, MA 02482
>
> *M: *+1 7209385761 <+1%207209385761> | john.lilley@redpointglobal.com
>
>
> PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is
> confidential and is intended solely for the use of the individual(s) to
> whom it is addressed. If you believe you received this e-mail in error,
> please notify the sender immediately, delete the e-mail from your computer
> and do not copy, print or disclose it to anyone else. If you properly
> received this e-mail as a customer, partner or vendor of Redpoint, you
> should maintain its contents in confidence subject to the terms and
> conditions of your agreement(s) with Redpoint.
>
>
> PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is
> confidential and is intended solely for the use of the individual(s) to
> whom it is addressed. If you believe you received this e-mail in error,
> please notify the sender immediately, delete the e-mail from your computer
> and do not copy, print or disclose it to anyone else. If you properly
> received this e-mail as a customer, partner or vendor of Redpoint, you
> should maintain its contents in confidence subject to the terms and
> conditions of your agreement(s) with Redpoint.
>

RE: Messages accumulating in management queue

Posted by John Lilley <jo...@redpointglobal.com.INVALID>.
We do keep a singleton ClientRequestor around forever.  Perhaps this is just wrong?  Is ClientRequestor cheap to make each time?

One of my colleagues found that occasionally closing and re-creating the ClientRequestor avoids this problem, but I’d like to know why.

I think you can see that image here:
https://drive.google.com/file/d/1gKDrg4-tRs7WSPbsqQ7Bu-UfhBPu4Fdj/view?usp=sharing

john





[rg] <https://www.redpointglobal.com/>

John Lilley

Data Management Chief Architect, Redpoint Global Inc.

888 Worcester Street, Suite 200 Wellesley, MA 02482

M: +1 7209385761<tel:+1%207209385761> | john.lilley@redpointglobal.com<ma...@redpointglobal.com>
From: Justin Bertram <jb...@apache.org>
Sent: Monday, January 16, 2023 9:48 AM
To: users@activemq.apache.org
Subject: Re: Messages accumulating in management queue

*** [Caution] This email is from an external source. Please use caution responding, opening attachments or clicking embedded links. ***

> I don’t know if that image comes through the mailing list...

I can't see your image. For what it's worth, attachments don't usually make it through the list.

Could you upload the image to another location and provide a link?

Also, could you provide the full stack-trace of the NPE?

I don't see in your code where you're actually closing the ClientRequestor so that might be a problem. Without more details it's impossible to say.


Justin

On Mon, Jan 16, 2023 at 10:31 AM John Lilley <jo...@redpointglobal.com.invalid>> wrote:
Greetings!

We are using the Artemis queue-based management APIs, and noticed that one of the two management queues that appears in the console starts to grow without bound:


I don’t know if that image comes through the mailing list, but it shows two of the xn--activemq-2p3d.management<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fxn--activemq-2p3d.management&c=E,1,yM5VuqjniGEfl7K4rM70Xa-2jC5pkpu2WMCuv2o_9ssgUAyqDzgAfPDtdn-xMCHxrbyaUxPnF2oUZkGoCF_o-vv_o42p3PRnI9YguDv7nT8RO5syVzebSQ,,&typo=1&ancr_add=1><UUID>”  queues, and one of the counts is in the 100s.  It just keeps growing and growing by about 300 per minute.

I’ve tried to browse this queue on the management console, but the browse() operation shows an NPE:
java.lang.NullPointerException : Cannot invoke "org.apache.activemq.artemis.core.paging.cursor.PageSubscription.iterator(boolean)" because "this.this$0.pageSubscription" is null

The calls we are making are like:
String resourceName = ResourceNames.QUEUE + queueName;
ClientRequestor client = getClient();
ClientSession clientSession = …
ClientMessage request = clientSession.createMessage(false);
ManagementHelper.putAttribute(request, resourceName, attributeName);
ClientMessage reply = client.request(request);

Or
ClientRequestor client = getClient();
ClientMessage request = clientSession.createMessage(false);
ManagementHelper.putAttribute(request, resourceName, attributeName);
ClientMessage reply = client.request(request);
if (ManagementHelper.hasOperationSucceeded(reply)) {
       for (var value : (Object[])ManagementHelper.getResult(reply, Object.class)) {
              result.add(value.toString());
       }

Any idea what we are doing wrong?

This happens on windows or linux

Artemis version 2.27.0.

java –version
openjdk 17.0.3 2022-04-19
OpenJDK Runtime Environment Temurin-17.0.3+7 (build 17.0.3+7)
OpenJDK 64-Bit Server VM Temurin-17.0.3+7 (build 17.0.3+7, mixed mode, sharing)

Thanks
john



[rg]<https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fwww.redpointglobal.com%2f&c=E,1,y0ymtXAc9XiBAplLMyDSTkbZPAR64gUyHhSGTjs8RK2_en31lUYrNYUf9Da_DM9WCm4_pRY8h4_s7PAUvD5SJfK1UCvi3Clxrot9XAr38A,,&typo=1>

John Lilley

Data Management Chief Architect, Redpoint Global Inc.

888 Worcester Street, Suite 200 Wellesley, MA 02482

M: +1 7209385761<tel:+1%207209385761> | john.lilley@redpointglobal.com<ma...@redpointglobal.com>

PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is confidential and is intended solely for the use of the individual(s) to whom it is addressed. If you believe you received this e-mail in error, please notify the sender immediately, delete the e-mail from your computer and do not copy, print or disclose it to anyone else. If you properly received this e-mail as a customer, partner or vendor of Redpoint, you should maintain its contents in confidence subject to the terms and conditions of your agreement(s) with Redpoint.

PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is confidential and is intended solely for the use of the individual(s) to whom it is addressed. If you believe you received this e-mail in error, please notify the sender immediately, delete the e-mail from your computer and do not copy, print or disclose it to anyone else. If you properly received this e-mail as a customer, partner or vendor of Redpoint, you should maintain its contents in confidence subject to the terms and conditions of your agreement(s) with Redpoint.

Re: Messages accumulating in management queue

Posted by Justin Bertram <jb...@apache.org>.
> I don’t know if that image comes through the mailing list...

I can't see your image. For what it's worth, attachments don't usually make
it through the list.

Could you upload the image to another location and provide a link?

Also, could you provide the full stack-trace of the NPE?

I don't see in your code where you're actually closing the ClientRequestor
so that might be a problem. Without more details it's impossible to say.


Justin

On Mon, Jan 16, 2023 at 10:31 AM John Lilley
<jo...@redpointglobal.com.invalid> wrote:

> Greetings!
>
>
>
> We are using the Artemis queue-based management APIs, and noticed that one
> of the two management queues that appears in the console starts to grow
> without bound:
>
>
>
>
>
> I don’t know if that image comes through the mailing list, but it shows
> two of the “activemq.management.<UUID>”  queues, and one of the counts is
> in the 100s.  It just keeps growing and growing by about 300 per minute.
>
>
>
> I’ve tried to browse this queue on the management console, but the
> browse() operation shows an NPE:
>
> java.lang.NullPointerException : Cannot invoke
> "org.apache.activemq.artemis.core.paging.cursor.PageSubscription.iterator(boolean)"
> because "this.this$0.pageSubscription" is null
>
>
>
> The calls we are making are like:
>
> String resourceName = ResourceNames.QUEUE + queueName;
>
> ClientRequestor client = getClient();
>
> ClientSession clientSession = …
>
> ClientMessage request = clientSession.createMessage(false);
> ManagementHelper.putAttribute(request, resourceName, attributeName);
> ClientMessage reply = client.request(request);
>
>
>
> Or
>
> ClientRequestor client = getClient();
>
> ClientMessage request = clientSession.createMessage(false);
> ManagementHelper.putAttribute(request, resourceName, attributeName);
> ClientMessage reply = client.request(request);
> if (ManagementHelper.hasOperationSucceeded(reply)) {
>        for (var value : (Object[])ManagementHelper.getResult(reply,
> Object.class)) {
>               result.add(value.toString());
>        }
>
>
>
> Any idea what we are doing wrong?
>
>
>
> This happens on windows or linux
>
>
>
> Artemis version 2.27.0.
>
>
>
> java –version
>
> openjdk 17.0.3 2022-04-19
>
> OpenJDK Runtime Environment Temurin-17.0.3+7 (build 17.0.3+7)
>
> OpenJDK 64-Bit Server VM Temurin-17.0.3+7 (build 17.0.3+7, mixed mode,
> sharing)
>
>
>
> Thanks
>
> john
>
>
>
> [image: rg] <https://www.redpointglobal.com/>
>
> John Lilley
>
> Data Management Chief Architect, Redpoint Global Inc.
>
> 888 Worcester Street, Suite 200 Wellesley, MA 02482
>
> *M: *+1 7209385761 <+1%207209385761> | john.lilley@redpointglobal.com
>
> PLEASE NOTE: This e-mail from Redpoint Global Inc. (“Redpoint”) is
> confidential and is intended solely for the use of the individual(s) to
> whom it is addressed. If you believe you received this e-mail in error,
> please notify the sender immediately, delete the e-mail from your computer
> and do not copy, print or disclose it to anyone else. If you properly
> received this e-mail as a customer, partner or vendor of Redpoint, you
> should maintain its contents in confidence subject to the terms and
> conditions of your agreement(s) with Redpoint.
>