activemq-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF subversion and git services (JIRA)" <>
Subject [jira] [Commented] (AMQ-6555) Failed to browse topic warnings caused by orphaned expire message tasks in Sceduler
Date Tue, 10 Jan 2017 15:27:58 GMT


ASF subversion and git services commented on AMQ-6555:

Commit e4da98bd790566ba2208246541f71a28b4a00c0f in activemq's branch refs/heads/activemq-5.14.x
from [~cshannon]
[;h=e4da98b ]

Fixing Scheduler so that a rescheduled task will first cancel the
existing task so it does not get orphaned from the task map.  Also
fixing Topic start so that it will only start once and not twice.

(cherry picked from commit 2769298cf64a10cd74320ad132b3677bac20a6cc)

> Failed to browse topic warnings caused by orphaned expire message tasks in Sceduler
> -----------------------------------------------------------------------------------
>                 Key: AMQ-6555
>                 URL:
>             Project: ActiveMQ
>          Issue Type: Bug
>    Affects Versions: 5.14.1
>            Reporter: jack
>            Assignee: Christopher L. Shannon
> When using a FixedCountSubscriptionRecoveryPolicy on a topic I get millions of warnings
when the topic is gc'd after inactivity. The impact is that warn logging has to be turned
off which is not ideal. Looking in detail it seems this is caused by a couple of things. Firstly
the Topic start method can be invoked twice, once when adding the destination to the RegionBroker
and second when the regionBroker is started. 
> That causes the same expireMessagesTask to get scheduled twice which reveals the crux
of the problem. The Scheduler allows the same task to be scheduled again in new TimerTasks,
even though it will use the same key and ophan any existing (and running) TimerTasks. This
is what's happening here. When the topic gets stopped, the orphaned tasks continue to run
causing these spurious warnings that clog up the logs.
> My suggestion would be for the scheduler to check if the task has already been registered
using a putIfAbsent and fail if it already exists:
> These are the warnings we see:
> 2017-01-10 11:36:13,885 [host] Scheduler] - WARN  Topic                          - Failed
to browse Topic: myTopic
> java.lang.NullPointerException
> 	at
> 	at
> 	at
> 	at$1(
> 	at$
> 	at
> 	at java.util.TimerThread.mainLoop(
> 	at

This message was sent by Atlassian JIRA

View raw message