Commit Graph

1004 Commits

Author SHA1 Message Date
Dmytro Chebotarskyi c35687052a Added additional logging on BrokerService startup
(cherry picked from commit dc55028c00)
2022-11-29 08:02:52 +01:00
Christopher L. Shannon (cshannon) 20dc305a49 AMQ-9175 - Properly set broker on ConnectionContext inside
MemoryTransactionStores

This fixes a NPE when using the messageDelivered advisory and
transactions

(cherry picked from commit f83c5f1ba1)
2022-11-21 11:12:07 -05:00
Christopher L. Shannon (cshannon) f90a7bf535 AMQ-9168 - Send message expired advisory and not discard advisory when
Topic subscriptions expire a message

This fixes topic subs to send the right advisory type, if enabled, when
the server discards a message on dispatch to a topic sub. Also add some
more expiration tests for other subscription types

(cherry picked from commit 757a712890)
2022-11-16 06:47:17 -05:00
Christopher L. Shannon (cshannon) 46cdecf05f (AMQ-9156, AMQ-9167) - Update TopicSubscription to use a new counter for
current dispatched count

The previous way of computing the count of using total dispatched minus
total dequeued didn't work in the case of destination removal and
messages were not acked. The counter is needed as the dispatched list is
optional unlike prefetch subs.

(cherry picked from commit 8554a1464c)
2022-11-15 17:02:11 -05:00
Matt Pavlovich d830dc2954 [AMQ-9163] Add 'Started' attribute to ConnectorView (#932)
(cherry picked from commit c25975389f)
2022-11-15 10:18:06 +01:00
Christopher L. Shannon (cshannon) 8062423dcd AMQ-9159 - In topic subscriptions only remove nodes from dispatched list if
they match the destination on destination removal

(cherry picked from commit 837df23be6)
2022-11-10 16:18:28 -05:00
Christopher L. Shannon (cshannon) 3bd099f469 AMQ-9156 - fix formatting 2022-11-03 10:44:26 -04:00
Christopher L. Shannon (cshannon) 9c5a6219ea AMQ-9156 - Make sure in flight metrics are properly decremented on
subscription destroys and dispatch failures

(cherry picked from commit 58666afffd)
2022-11-03 10:42:45 -04:00
Christopher L. Shannon (cshannon) 8cc7a45455 AMQ-9107 - rework performance improvement for consumer closing in
managed region broker

This new approach just looks matching Subscriptions from the region for the
destination which prevents having to store another map and falls back to
the old approach if something went wrong.

(cherry picked from commit d46b74d674)
2022-11-03 06:50:44 -04:00
Christopher L. Shannon (cshannon) bc9e728123 AMQ-9153: Fix slow consumer advisory for queue subscriptions
Due to changes with Queues to check if consumers are full before adding
more messages to the subscription, the Queue dispatch logic needed to be
updated to mark subscriptions as slow and send advisories if configured
instead of relying on the subscription itself to do it.

(cherry picked from commit 596ee31687)
2022-11-01 10:31:50 -04:00
Lucas Tétreault 51c390737a remove consumers more efficiently
(cherry pick from commit b7f73d4875)
2022-10-13 05:58:32 +02:00
Robbie Gemmell aad85e2c4a AMQ-9074: use -noindex to remove various .js files, disable html source listings for javadoc
(cherry picked from commit 52574a794a)
2022-09-07 18:04:01 -04:00
Jean-Baptiste Onofré cad3839fe1 [maven-release-plugin] prepare for next development iteration 2022-08-25 09:22:35 +02:00
Jean-Baptiste Onofré b6ecffe80a [maven-release-plugin] prepare release activemq-5.17.2 2022-08-25 09:22:27 +02:00
Jean-Baptiste Onofré 7ad4c551fd [AMQ-9049] Mention dicarded messages in getTotalDequeueCount operation of BrokerViewMBean
(cherry picked from commit 7159b4410b)
2022-08-18 07:26:47 +02:00
Zishuo Ding 2a7570d7d8 Refine the logging messages
(cherry picked from commit f2c9a6c718)
2022-08-17 07:49:06 +02:00
Lucas Tétreault 020519f54f Clean up remaining Xalan references
(cherry picked from commit 7b3f13feda)
2022-08-12 08:08:37 +02:00
Lucas Tétreault c44008e852 [AMQ-9005] remove xalan dependency due to it being end of life
(cherry picked from commit e550748b4c)
2022-08-01 06:39:51 +02:00
Jean-Baptiste Onofré 8abb50aa16 [maven-release-plugin] prepare for next development iteration 2022-04-25 14:23:42 +02:00
Jean-Baptiste Onofré 0898aab016 [maven-release-plugin] prepare release activemq-5.17.1 2022-04-25 14:23:33 +02:00
Jean-Baptiste Onofré bd08484445 [maven-release-plugin] prepare for next development iteration 2022-03-09 21:47:58 +01:00
Jean-Baptiste Onofré 1f3ccad9bb [maven-release-plugin] prepare release activemq-5.17.0 2022-03-09 21:47:47 +01:00
Jean-Baptiste Onofré a9cb53bd38 Cancel 5.17.0 release 2022-03-09 21:42:04 +01:00
Jean-Baptiste Onofré 2582384511 [maven-release-plugin] prepare for next development iteration 2022-03-07 15:41:59 +01:00
Jean-Baptiste Onofré 8ad238bb7d [maven-release-plugin] prepare release activemq-5.17.0 2022-03-07 15:41:49 +01:00
Christopher L. Shannon (cshannon) da9e5276f1 AMQ-8520: Log4j2 test fixes
Also fixes Log4jConfigView

(cherry picked from commit ae30dce4e2)
2022-03-03 16:42:22 -05:00
Christopher L. Shannon (cshannon) 8a4c928806 Revert "[AMQ-7309] Update to jakarta.jms/jakarta.jms-api:2.0.3 (#682)"
This reverts commit 67256c61b1.
2022-03-01 10:25:01 -05:00
Jean-Baptiste Onofré e597017200
Merge pull request #662 from jbonofre/AMQ-7426
[AMQ-7426] Upgrade to log4j2
2022-02-27 13:23:53 +01:00
Matt Pavlovich 9956dd602a
[AMQ-8440] Set sendDuplicateFromStoreToDLQ to 'false' by default (#773) 2022-02-24 08:45:35 -06:00
jbonofre 472dcf8497 [AMQ-7426] Upgrade to log4j2 2022-02-24 15:20:51 +01:00
Christopher L. Shannon (cshannon) df354fa023 AMQ-8509: Update TempStore Usage test to verify cleanup
Add a unit test to the previous tests added in AMQ-7085 to verify
TempUsage is cleaned up and stopped on Queue.stop()
2022-02-23 07:41:24 -05:00
Artur Pedroso d1e9ba68b3 AMQ-8509: Fix TempUsage memory leak
If you have an application that creates lots of queues it will eventually
fail with OOM because TempUsage is started on Queue#start but never stopped.

The `systemUsage.getTempUsage().start()` used on the Queue#start
adds elements on a List from TempUsage parent and these elements
are never removed.

To reproduce this issue you need to leave an application
running for a long time creating different queues.

The only way to avoid the leak right now is to stop the BrokerService,
which isn't a solution.
2022-02-23 07:38:58 -05:00
Endre Stølsvik 9167a79b79 StatisticsBrokerPlugin: Add feat: request destination firstMessageTimestamp
Adding a feature (STATS_FIRST_MESSAGE_TIMESTAMP) to the
StatisticsBrokerPlugin's destination-statistics for getting the
timestamp of the first message in the destination(s) being requested: If
you on the query-message set the property
StatisticsBroker.STATS_FIRST_MESSAGE_TIMESTAMP to anything (e.g. boolean
true), a long value "firstMessageTimestamp" will be added to the
statistics reply message(s). Since the reply message has JMSTimestamp
set, which is the broker's now-timestamp, you may also on the query side
calculate the age of the first message in milliseconds. The key name was
chosen since that is the name of the corresponding feature in Artemis.

This extension of the existing feature is implemented to be as
non-intrusive as possible, adding very little runtime cost if not
requested. It also seems like the runtime cost for enabling this
feature, thus finding and adding the firstMessageTimestamp, is small.

While at it, also slightly improving an existing feature
(STATS_DENOTE_END_LIST) where a reply to a destination query can be
"null terminated": After sending the relevant replies, the
StatisticsBroker also sends an empty message. This feature is relevant
if the query is a wildcard query, thus returning multiple messages: The
empty message denotes the end of the replies. However, to activate this
feature, a somewhat complicated query destination had to be constructed.
Adopting the solution for the other StatisticsBroker feature where you
may reset the broker statistics by adding a property to the query
message, this null-termination feature now /also/ checks for the
presence of this query modifier STATS_DENOTE_END_LIST as a property.
(This property based solution was thus also adopted for the present
'firstMessageTimestamp' solution, as it was found much more intuitive).

Added tests for both the STATS_FIRST_MESSAGE_TIMESTAMP query modifier,
and the improved STATS_DENOTE_END_LIST property-based query modifier.

Had to make the Topic.doBrowse(List browseList, int max) public - the
corresponding method for Queue was already public.

Made the evaluation of whether this is a StatisticsBroker-relevant
message a microscopic bit more performant (exiting faster if not
relevant): To the initial test of whether the message is relevant, which
only checked for replyTo being set, a check for 'destination.
startsWith("ActiveMQ.Statistics")' was added. Only if so, the rest of
the evaluations kick in. Also using 'string.startsWith(..)' instead of
the verbose 'string.regionMatches(..)'.

Removed an unused import on PartitionBrokerTest.java, as IntelliJ
complained about not finding it.
2022-01-25 09:45:48 +01:00
Matt Pavlovich 6a944a05d9 [AMQ-8462] Remove double call to listConnectionStates during connection close 2022-01-24 09:21:19 -06:00
Jean-Baptiste Onofré 3d2fb2b609
Merge pull request #707 from AlexejTimonin/sendTextMessageWithProperties-delimiter
[AMQ-8372] Allow custom delimiter when sending TextMessages via MBean
2022-01-22 17:14:03 +01:00
Jean-Baptiste Onofré 0508c22481
Merge pull request #742 from mattrpav/AMQ-8053
[AMQ-8053] Do not override JMSXUserID over network connections
2022-01-15 06:47:48 +01:00
Jean-Baptiste Onofré 2f96b4a60c [AMQ-8252] Introduce stackTraceEnabled flag on transport connector to define if the stack trace should be displayed or not in case of WARN messages 2022-01-14 11:37:44 +01:00
Matt Pavlovich bec734a133 [AMQ-8043] Do not override JMSXUserID when message comes across network connector 2022-01-12 09:00:20 -06:00
Matt Pavlovich 05426d637c
[AMQ-8397] Add a destination option to sendDuplicateFromStoreToDLQ (#724)
- Default 'true' to match existing behavior
 - Added counter to DestinationView
2021-12-20 08:38:32 -06:00
Matt Pavlovich b196e9a88a
[AMQ-8400] Add synchronization handling for Transaction to prevent CME (#720) 2021-12-20 08:37:56 -06:00
Matt Pavlovich ee768a28d6
[AMQ-8413] Add remoteUserName and remotePassword config fields to network connector (#725) 2021-12-20 08:36:56 -06:00
Matt Pavlovich 67256c61b1
[AMQ-7309] Update to jakarta.jms/jakarta.jms-api:2.0.3 (#682)
- API update only
 - Throw UnsupportedOperationException
 - Disable activemq-camel from build
 - Formatting fixes
 - Use geronimo-jms for osgi-related artifacts
 - Fix features.xml invalid xml header
 - Add a unit test to confirm JMS 2.0 methods for phase 1 (throw UnsupportedOperationException)
 - Add deliveryTime field to Message
 - Minor formatting fixes
2021-11-10 11:56:04 -06:00
Romain Manni-Bucau 6fea79d1a9 Ensure to not depend on sun.rmi.registry.RegistryImpl 2021-10-26 17:40:59 +02:00
Jean-Baptiste Onofré f74992c105 [AMQ-8395] Avoid possible NPE when sending advisory message 2021-10-04 10:14:32 +02:00
Alexej Timonin 7c63227003 Allow custom delimiter when sending TextMessages via MBean
This enables possibility to send messages containing commas in the body
with tools such as jconsole.
Example simple text as body: body=Hello, world!
Example json as body: body={"a":"b","c":"d"}
2021-09-04 22:31:22 +02:00
Christopher L. Shannon (cshannon) 8b99596eeb AMQ-8349 - Ensure virtual destination consumer advisories are only
replayed to new advisory consumers and not existing
2021-08-05 09:58:37 -04:00
Jean-Baptiste Onofré ceaeaa986b [AMQ-8252] Doesn't display warn stack trace for stomp (regression compared to 5.15.x) 2021-08-04 07:48:10 +02:00
Matt Pavlovich c0d5399635
[AMQ-8285] Add 'slow' metrics to PersistenceAdapterStatistics (#664) 2021-06-04 06:19:54 +02:00
Jean-Baptiste Onofré ae777e9571
Merge pull request #665 from mattrpav/AMQ-8282
[AMQ-8282] Migrate from deprecated .newInstance() calls to .getConstr…
2021-06-04 06:18:27 +02:00
Colm O hEigeartaigh 7ca7118a95 AMQ-8117 - Allow java.util arrays for deserialization 2021-06-03 14:42:42 +01:00