Commit Graph

903 Commits

Author SHA1 Message Date
saurabhrai 4abca78785 ARTEMIS-1364: Enable internal sorting in hawtio web console 2017-11-29 08:52:33 +00:00
saurabhrai 6315e3faf0 ARTEMIS-1505: NPE prevents browsing queue with large messages 2017-11-27 15:01:34 -05:00
Pat Fox 4edf6793bb ARTEMIS-1524 avoid null pointer due to race condition in listAddresses(). If address is deleted, ignore that address and continue 2017-11-27 13:05:12 -05:00
Justin Bertram f53e411dad ARTEMIS-1525 refactor embedded examples 2017-11-27 10:55:16 -06:00
Justin Bertram 40aa3f5821 ARTEMIS-1513 fix AMQP + core bridge 2017-11-21 09:44:30 -05:00
Clebert Suconic b27ed5de16 ARTEMIS-1514 Fix File open on Large Message 2017-11-21 09:27:27 -05:00
Martyn Taylor eddb144deb ARTEMIS-1514 Fix read large message into buffer 2017-11-21 13:23:12 +00:00
Howard Gao 5fe88e1c66 ARTEMIS-1365 Advisory consumers listed in Console
Openwire clients create consumers to advisory topics to receive
notifications. As a result there are internal queues created
on advisory topics. Those consumer shouldn't be exposed via
management APIs which are used by the Console

To fix that the broker doesn't register any queues from
advisory addresses.

Also refactors a code to remove Openwire specific contants
from AddressInfo class.
2017-11-17 17:39:40 +08:00
Clebert Suconic 9daa0321b6 ARTEMIS-1514 Large message fix
I'm doing an overal improvement on large message support for AMQP
However this commit is just about a Bug on the converter.

It will be moot after all the changes I'm making, but I would rather keep this separate
as a way to cherry-pick on previous versions eventually.
2017-11-15 20:54:58 -05:00
Howard Gao 19c6f2d5c4 NO-JIRA Added test coverage for broker paging with unlimited memory
This test starts 2 servers and send messages to
a queue until it enters into paging state. Then
it changes the address max-size to -1, restarts
the 2 servers again and consumes all the messages.
It verifies that even if the max-size has changed
all the paged messages will be depaged and consumed.
No stuck messages after restarting.

The tests is there to guard a case where messages
won't be depaged on server restart after the max-size
is changed to -1. This issue has been fixed into
master along with the fix for ARTEMIS-581, particularly
the changes to the method PagingStoreImpl.getMaxSize().
2017-11-15 17:19:30 -05:00
Clebert Suconic 68705a5a63 NO-JIRA Making sure System.properties are cleaned up between tests 2017-11-15 17:14:34 -05:00
Justin Bertram 55d7260a07 ARTEMIS-1510 refactor Maven poms
Clean up unused declared dependencies and undeclared dependencies which
are pulled in transitively.
2017-11-13 17:03:35 -05:00
Clebert Suconic 63b156e290 ARTEMIS-1495 Test Improvements
Server.stop is currently waiting completions on Sessions just because of test cases.

With the recent changes made into the Executors this is not needed any longer
2017-11-13 16:46:32 -05:00
Clebert Suconic 91db08072b ARTEMIS-1495 Fixing In Handler executor and added benchmark to measure impact of changes 2017-11-09 11:58:36 -05:00
Clebert Suconic 2e6176a693 ARTEMIS-1495 Removing flushes from codebase
Instead of flushing we just need to make sure there are no more calls into
page executors as we stop the PageManager.

This will avoid any possible starvations or deadlocks here.
2017-11-09 11:58:36 -05:00
Clebert Suconic 559a704818 ARTEMIS-1416 Fixing testsuite 2017-11-03 18:27:42 -04:00
Stanislav Knot a5c0c024fa ARTEMIS-1486 added JMS client test 2017-11-03 10:53:05 -04:00
Justin Bertram 096d98407f ARTEMIS-1492 obfuscate passwords in acceptorControl 2017-11-02 20:46:26 -04:00
Clebert Suconic 7f4a79b0c6 NO-JIRA Fixing intermittent test failures 2017-11-02 09:37:31 -04:00
Stanislav Knot 61ce7a7454 ARTEMIS-1486 Core client should be notified if consumer is closed on broker side 2017-11-02 11:19:35 +00:00
Justin Bertram 8703d9d51d [maven-release-plugin] prepare for next development iteration 2017-11-01 00:38:57 -05:00
Justin Bertram ec63189a0a [maven-release-plugin] prepare release 2.4.0 2017-11-01 00:38:56 -05:00
Justin Bertram a44b9d5edf [maven-release-plugin] prepare for next development iteration 2017-10-31 12:09:43 -05:00
Justin Bertram 34a7431d1b [maven-release-plugin] prepare release 2.4.0 2017-10-31 12:07:55 -05:00
Clebert Suconic 2bf690e21b ARTEMIS-1489 Adding Timed Buffer into Critical Analyzer 2017-10-31 08:33:44 -05:00
Erich Duda fb76d9aeb0 ARTEMIS-1485 ActiveMQTestBase.threadDump should print information about locks and deadlocks
Improved implementation of ActiveMQTestBase.threadDump which uses ThreadMXBean
for getting information about threads including locks and deadlocks.
2017-10-31 08:04:11 +01:00
Clebert Suconic 1af6d986a5 ARTEMIS-1447 Reuse thread pools on JDBC Locks
I had moved the initialization of the thread pools for that..
I also have changed the CrticialAnalyzer to use the same pools as part of this
2017-10-27 22:32:53 -04:00
Francesco Nigro 33cab063ea ARTEMIS-1447 JDBC NodeManager to support JDBC HA Shared Store
It fixes the NPE on server start due to:
 - missing SqlProviderFactory
 - missing executor factory/scheduled pool (ie using exclusive scheduled pools)

It fixes the WARNINGS due to wrong slowness detection while renewing JdbcLeaseLock.
2017-10-27 12:26:48 -05:00
Francesco Nigro 09a5d6f1c6 ARTEMIS-1447 JDBC NodeManager to support JDBC HA Shared Store 2017-10-26 15:38:37 -04:00
Chris Burlinchon 06dab31fd0 ARTEMIS-1479 Fix set validated user in large messages 2017-10-25 11:44:14 -04:00
Justin Bertram de1165df6e ARTEMIS-1420 prevent potential NPE 2017-10-25 09:00:10 -05:00
Stanislav Knot 6faffd690e ARTEMIS-1420 enforce timeout on network client handshake 2017-10-24 14:28:23 -05:00
Andy Taylor a64d7c2e42 ARTEMIS-1463 - added SSL example + docs
also added support for anon login

https://issues.apache.org/jira/browse/ARTEMIS-1463
2017-10-18 15:24:44 -05:00
Clebert Suconic fdcae9d32a ARTEMIS-450 Fixing deadlock over lots of rollbacks and Queue.addHead 2017-10-18 12:21:47 -04:00
Justin Bertram eee72a61d1 ARTEMIS-1456 use queue name when null address on createQueue 2017-10-17 10:03:33 +01:00
Andy Taylor 12ad0120ad ARTEMIS-1463 - add role based authentication to the JMX objects
some example fixes

https://issues.apache.org/jira/browse/ARTEMIS-1463
2017-10-17 10:02:46 +01:00
Howard Gao 105d8c3388 ARTEMIS-1366 Hide Advisory Address from Management Console
Openwire consumer is listed twice below "consumers" tab.
First it shows correctly the requested queue consume.
Second it shows consumer from multicast queue ActiveMQ.Advisory.
The second one is internal and should be hidden.
2017-10-16 16:51:54 -05:00
Andy Taylor 62a2b14dd0 ARTEMIS-1463 - add role based authentication to the JMX objects
This is done by creating a guard and using JAAS to check for access to mbean objects and their methods.

NB this also implements https://issues.apache.org/jira/browse/ARTEMIS-534

https://issues.apache.org/jira/browse/ARTEMIS-1463
2017-10-16 15:39:38 +01:00
Clebert Suconic ea89833204 ARTEMIS-1446 Use Contructor on TransformerConfiguration 2017-10-10 15:17:31 -04:00
Michael Andre Pearce 4db8cd54ca ARTEMIS-1446 - Support Transformer configuration by properties
Update Tranformer to be able to handle initiation via propertiers (map<string, string>)
Update Configuration to have more specific transfromer configuration type, and to take properties.
Support back compatibility.
Add AddHeadersTransformer which is a main use case, and can act as example also.
Update Control's to expose new property configuration
Add test cases
Update examples for new transformer config style
2017-10-09 17:29:10 -04:00
Clebert Suconic d190b611be ARTEMIS-1452 Improvements to IO parameters and options
- it is now possible to disable the TimedBuffer
- this is increasing the default on libaio maxAIO to 4k
- The Auto Tuning on the journal will use asynchronous writes to simulate what would happen on faster disks
- If you set datasync=false on the CLI, the system will suggest mapped and disable the buffer timeout

This closes #1436

This commit superseeds #1436 since it's now disabling the timed buffer through the CLI
2017-10-09 14:32:04 -04:00
Clebert Suconic ba1323c8b2 ARTEMIS-1455 Fixing issues on Large Message conversion 2017-10-09 14:32:03 -04:00
Clebert Suconic 484e939698 NO-JIRA: Speed up cleanupThreads for testsuite 2017-10-09 14:32:03 -04:00
Dmitrii Tikhomirov 53efdbab49 ARTEMIS-1455 HQ222142: Error on resetting large message deliver - null: java.lang.NullPointerException 2017-10-09 12:54:46 -04:00
Clebert Suconic 1d5fe2862a ARTEMIS-1444 Fixing byte buffer conversion
I'm also using a lower size on message, to speed up the new test.

(100M may be a lot on some CIs)
2017-10-09 12:50:38 -04:00
Martyn Taylor 988c91557d ARTEMIS-1444 Support Messages > JournalBufferSize in all Protocols 2017-10-09 12:50:38 -04:00
Clebert Suconic 30ba65a082 NO-JIRA: Fixing the testsuite on Page.finalize() 2017-10-07 12:05:55 -04:00
Clebert Suconic bb554e5264 ARTEMIS-1397 Removing Netty Copied classes
instead of duplicating a buffer from Netty, this will use an existing Wrapped Unpooled Buffer
Which will in turn use Unsafe Properly.
2017-10-02 17:06:06 -04:00
Ryan Yeats 420421c90b ARTEMIS-1397 remove package private access to netty 2017-10-02 09:33:47 -04:00
Clebert Suconic aa3e8941d1 ARTEMIS-1442 Shutdown server if can't move file on journal 2017-09-29 11:35:47 -04:00
Clebert Suconic 178d403117 NO-JIRA Adding CriticalAnalyzer test on HALT 2017-09-29 11:35:47 -04:00
Clebert Suconic 1b0fc06196 ARTEMIS-1440 ForceFailover to be asynchronous and allow management 2017-09-29 09:34:30 -04:00
Dmitrii Tikhomirov 7c433e527a ARTEMIS-1382 Improve artemis-server logging 2017-09-28 21:41:40 -04:00
Michael Andre Pearce b53b3acdb4 ARTEMIS-1439 Upgrade Netty to 4.1.16
Upgrade netty.
Remove tacticle fix for https://issues.apache.org/jira/browse/ARTEMIS-1099
as now fixed/handled upstream in netty from 4.1.16 https://github.com/netty/netty/issues/7150
2017-09-28 13:51:00 -05:00
Clebert Suconic 796c4f2c4e ARTEMIS-1441 Critical Analyzer Check Period not properly parsed 2017-09-27 20:59:05 -04:00
Clebert Suconic 8b68e8f48a NO-JIRA: some more organization on critical analyzer 2017-09-27 12:57:42 -04:00
Clebert Suconic 78f5ab096f NO-JIRA: Refactoring method on critical analyzer
Same semantics, no need for jira here
2017-09-26 17:27:04 -04:00
Clebert Suconic b2c5cb06ec NO-JIRA: Parse System properties first 2017-09-26 16:49:17 -04:00
Justin Bertram abcf4b747e ARTEMIS-1428 support max frame payload length for STOMP websocket 2017-09-26 15:17:07 -04:00
Michael Andre Pearce e9eaa7daf6 ARTEMIS-1422 Fix match change to support wildcard config 2017-09-25 11:34:34 -04:00
Pat Fox 50fcd48e28 ARTEMIS-1433 adding AddressMemoryUsage() and AddressMemoryUsagePercentage() to ActiveMQServerControl 2017-09-25 10:37:16 -04:00
Jeff Mesnil 0010b0a090 [ARTMIS-1431] Adapt transport configuration in ClientProtocolManagerFactory
add the adaptTransportConfiguration() method to the
ClientProtocolManagerFactory so that transport configurations used by
the ClientProtocolManager have an opportunity to adapt their transport
configuration.

This allows the HornetQClientProtocolManagerFactory to adapt the
transport configuration received by remote HornetQ broker to replace the
HornetQ-based NettyConnectorFactory by the Artemis-based one.

JIRA: https://issues.apache.org/jira/browse/ARTEMIS-1431
2017-09-25 10:33:56 -04:00
Pat Fox 89a64ff11c ARTEMIS-1423 adding numeric filtering for ActiveMQServerControl.listQueues()/listAddresses()/listSessions() 2017-09-18 15:15:31 -05:00
Justin Bertram be3a66f016 ARTEMIS-1421 duplicate queue possible in XML 2017-09-13 18:26:28 -04:00
Howard Gao e4fb722ad8 ARTEMIS-1419 OpenWire advisory message never deleted
By default, every openwire connection will create a queue
under the multicast address ActiveMQ.Advisory.TempQueue.
If a openwire client is create temporary queues these queues
will fill up with messages for as long as the associated
openwire connection is alive. It appears these messages
do not get consumed from the queues.

The reason behind is that advisory messages don't require
acknowledgement so the messages stay at the queue.
2017-09-13 18:21:43 -04:00
Michael Andre Pearce 7d943cc6f7 ARTEMIS-1405: Fix PurgeOnNoConsumer queue config is not persisted on restart
Added integration test, to prove issue, and assert fix.
Fix PersistentQueueBindingEncoding to return value, not false.
Fix some method arg name to align with class interface arg name
2017-09-13 18:21:13 -04:00
Clebert Suconic 8156879cf1 ARTEMIS-1418 Fixing compilation 2017-09-13 16:19:39 -04:00
Martyn Taylor 520a40b1a1 ARTEMIS-1418 AIO Shutdown on IOError and logging 2017-09-13 16:09:21 +01:00
Justin Bertram 2ec173bc70 ARTEMIS-1417 Failback not working on NFSv4
With NFSv4 it is now necessary to lock/unlock the byte of the server
lock file where the state information is written so that the
information is then flushed to the other clients looking at the file.
2017-09-13 11:44:38 +01:00
Timothy Bish a07cb45222 ARTEMIS-1400 Fix some minor issues spotted with FindBugs
Remove a bit of dead code, and invert two string tests that were testing
for null after comparing the value to empty string (NPE scenario).
2017-09-11 12:08:02 -04:00
Christopher L. Shannon (cshannon) 983ec7eb88 ARTEMIS-1403 - Fix wildcard matching to always respect delimiters
The regular expressions for wildcard matching now properly respects the last
delimiter in a pattern and will not match a pattern missing the
delimiter by mistake
2017-09-07 10:45:50 -04:00
Francesco Nigro 9cf222be11 ARTEMIS-1393 CriticalAnalyzer timeout uses System::currentTimeMillis
The timeout logic is changed to use System::nanoTime, less sensible to OS clock changes.
The volatile set on CriticalMeasure are changed with cheaper lazySet.
2017-09-07 10:11:35 -04:00
gtully 99b2e4c0fb ARTEMIS-1373 - support memberOf type query for role mapping and respect roleName attribute AMQ-3064 2017-09-07 14:11:48 +01:00
Martyn Taylor 16dfd777b8 ARTEMIS-1387 Fix AMQPtoMQTT and Link route issues 2017-09-06 11:21:56 +01:00
gtully 125bd41f9d ARTEMIS-1372 ARTEMIS-1373 documentation updates 2017-09-06 10:22:28 +01:00
Clebert Suconic c8982d775b [maven-release-plugin] prepare for next development iteration 2017-09-05 17:03:48 -04:00
Clebert Suconic 84d5ac65b4 [maven-release-plugin] prepare release 2.3.0 2017-09-05 17:03:37 -04:00
gtully 5db68a451b ARTEMIS-1372 - alow auth to ldap via kerberos 2017-09-05 16:35:14 -04:00
gtully ab7dc69b5d ARTEMIS-1373 - allow LDAP login module apply role mapping to existing user principals in the subject 2017-09-05 16:35:14 -04:00
Howard Gao cd551bfba0 ARTEMIS-1389 Add non-null check to ServerSessionImpl.doClose()
An Openwire connection creates an internal session used to track
transaction status, it doesn't have a session callback. When
the connection is closed, the core session should check if
callback is null to avoid NPE.
2017-09-05 16:16:33 -04:00
Pat Fox 4618b192c2 ARTEMIS-1381 add JMX operation removeAllMessages() to the queue
fix checkstyle trailing spaces
2017-09-01 00:55:07 +02:00
Clebert Suconic ed1b268d42 [maven-release-plugin] prepare for next development iteration 2017-08-31 13:48:09 -04:00
Clebert Suconic 21f2a4a52c [maven-release-plugin] prepare release 2.3.0 2017-08-31 13:47:57 -04:00
Clebert Suconic 6483e4a0aa ARTEMIS-1378 Improving update Queues and Addresses 2017-08-30 22:45:33 -04:00
Justin Bertram 2f5a9322d0 ARTEMIS-1379 Some queue stats not threadsafe 2017-08-30 10:53:43 -04:00
Clebert Suconic f37093e33c ARTEMIS-1378 Removing System.out left by accident 2017-08-30 10:41:11 -04:00
Clebert Suconic 0df12657af ARTEMIS-1378 Update Address is broken, may lose messages 2017-08-29 20:48:01 -04:00
Clebert Suconic 6fda75a9fc ARTEMIS-1297 Load balance or redistribution of AMQP Messages 2017-08-29 12:56:15 -05:00
Michael Andre Pearce 9fbbb7c416 ARTEMIS-1361 - Support Updating queue config from broker.xml at runtime
Add support to update Queue config via reload using existing updateQueue method at runtime.
Add/extend unit test cases to include testing reload of queue config.
2017-08-25 22:46:50 -04:00
Clebert Suconic f2d74e7a43 ARTEMIS-1367 Moving CriticalAnalyzerPolicy 2017-08-24 18:08:01 -04:00
Michael Andre Pearce 45ea110f62 ARTEMIS 1369: Include queue name in security errors
Add new error in message bundle to include queue
update security check to support taking optional queue
update code that is operating on queues to pass the queue name during check so queue name could be in the error log if security issue.
2017-08-23 11:00:52 -04:00
Clebert Suconic aa2f0b9f17 ARTEMIS-1356 Fixing assertion logic 2017-08-23 09:05:36 -04:00
Erich Duda d6cbc0aa88 ARTEMIS-1368 Artemis gets to state when it doesn't respond to producer
There is a leak on replication tokens in the moment when a backup is
shutdowned or killed and the ReplicationManager is stopped. If there
are some tasks (holding replication tokens) in the executor, these
tokens are simply ignored and replicationDone method isn't called on
them. Because of this, some tasks in OperationContextImpl cannot be
finished.
2017-08-23 12:46:47 +02:00
Francesco Nigro e0881448c1 ARTEMIS-1356 Avoid allocations and atomic operations to recognize handler's thread 2017-08-22 22:12:26 -04:00
Francesco Nigro 249745506e ARTEMIS-1367 Add LOG to the Critical Analyzer policies 2017-08-22 17:37:01 +02:00
Clebert Suconic ce6942a9aa ARTEMIS-1353 Initial replication of large messages out of executor
This is based on the work @jbertram made at the github pr #1466 and the discussions we had there
2017-08-18 16:19:25 -04:00
Andy Taylor 4ee9580e69 ARTEMIS-1350 - Added close button to console for client objs
https://issues.apache.org/jira/browse/ARTEMIS-1350
2017-08-18 13:55:37 +01:00
Christopher L. Shannon (cshannon) 03785a3142 ARTEMIS-1347 - Pass the QueueBinding to beforeCreateConsumer
Instead of just the queue name the entire QueueBinding object is now
passed to the beforeCreateConsumer plugin method. Also cleaned up some
comments
2017-08-17 10:14:11 -05:00
Martyn Taylor bb3965b7f7 ARTEMIS-1349 Add management views for client objects 2017-08-17 10:44:41 +01:00
Clebert Suconic 69e345f291 ARTEMIS-1333 oops 2017-08-10 21:46:27 -04:00
Christopher L. Shannon (cshannon) 64bacee28a ARTEMIS-1332 Always return a response to the client on session metadata add
This will make sure that if there is an ActiveMQException thrown the
client will get notified and not hang.
2017-08-10 12:28:14 -04:00
Clebert Suconic 012fe58b2c ARTEMIS-1333 fixing test, cannot flush itself from Runnable 2017-08-09 16:02:10 -04:00
Michael Andre Pearce 0bc5510059 ARTEMIS-1342: Support Netty Native KQueue on macOS
Add support for KQueue for when server or client runs on macOS. This is inline with the epoll support for linux.
2017-08-09 15:23:16 -04:00
Clebert Suconic fabc0701a3 ARTEMIS-1333 SendACK listener fix 2017-08-09 15:18:54 -04:00
Clebert Suconic 96c6268f5a ARTEMIS-1333 SendACK listener message loss (adding test)
next commit should have the fix.
this is to make it easy to confirm the fix by people looking.
2017-08-09 15:18:54 -04:00
Clebert Suconic 1ace306121 ARTEMIS-1328 Improving direct delivery check
Instead of wait to flush an executor,
I have added a method isFlushed() which will just translate to the
state on the OrderedExecutor.

In the case another executor is provided (for tests) there's a delegate
into normal executors.
2017-08-08 14:00:58 -04:00
gtully 9fedb47c40 [ARTEMIS-1310] [ARTEMIS-1264] consolidate configuration to require login configuration scope 2017-08-08 13:28:50 -04:00
gtully ca7197b5c3 [ARTEMIS-1310] add amqp sasl gssapi mechanism support
delegate to the jdk saslServer. Allow acceptor configuration of supported mechanismis; saslMechanisms=<a,b>
and allow login config scope for krb5 to be configured via saslLoginConfigScope=x
2017-08-08 13:28:50 -04:00
Clebert Suconic f16af75354 ARTEMIS-1324 Deadlock detection and health check of critical components 2017-08-07 18:40:03 -04:00
Clebert Suconic 7bd454739c ARTEMIS-1327 changing exception hangling on plugins 2017-08-07 16:26:37 -04:00
Christopher L. Shannon (cshannon) a3a614ee8b ARTEMIS-1327 - Support checked exceptions in ActiveMQServerPlugin
This will allow plugin writers to use checked exceptions when writing
plugins
2017-08-07 16:24:19 -04:00
Justin Bertram b6b8fa411f ARTEMIS-1322 ServerLocator option to ignore topology for load-balancing 2017-08-04 13:56:30 -05:00
Michael Andre Pearce 776ec0b9fd ARTEMIS-1313 getAddresses in PostOfficeImpl does not correctly return all addresses
Fix so that getAddresses uses addressInfoMap instead of the mappings so that addresses without queues also are returned
2017-08-02 12:50:34 -04:00
Justin Bertram 610737bc30 ARTEMIS-1306 clarify identity for authn failures 2017-07-28 18:00:06 -04:00
Martyn Taylor 69f8263267 ARTEMIS-1303 Fix interleave during replication sync 2017-07-26 10:25:47 +01:00
Clebert Suconic fdad83be22 [maven-release-plugin] prepare for next development iteration 2017-07-24 21:21:18 -04:00
Clebert Suconic 71b1cc2a20 [maven-release-plugin] prepare release 2.2.0 2017-07-24 21:21:06 -04:00
Justin Bertram 59841b8872 ARTEMIS-1302 make quorum voting more transparent 2017-07-21 19:39:06 -05:00
Clebert Suconic 8f5f2bbe52 ARTEMIS-1300 Deadlock when Core direct deliverying and AMQP receive 2017-07-20 08:59:32 -04:00
Martyn Taylor e742de7d6e ARTEMIS-1290 QueueQuery add prefix on address 2 2017-07-18 16:16:42 -04:00
Martyn Taylor 34df3afe0c Revert "ARTEMIS-1290 QueueQuery add prefix on address"
This reverts commit 44506f2258.
2017-07-18 16:16:42 -04:00
Clebert Suconic 41a03de02f ARTEMIS-1287/ARTEMIS-1292 Fixing intermittent failure on reconnects 2017-07-18 10:24:39 -04:00
Andy Taylor 6f140897c6 ARTEMIS-1296 - fix quorum vote
Add a check on top of just being able to connect to a live broker

https://issues.apache.org/jira/browse/ARTEMIS-1296
2017-07-18 08:10:11 +01:00
Martyn Taylor 44506f2258 ARTEMIS-1290 QueueQuery add prefix on address 2017-07-17 10:31:20 -04:00
Michael Andre Pearce 2cbee11230 ARTEMIS-1289 Fix: Unable to configure queues containing "/" in broker.xml 2017-07-17 10:41:02 +01:00
Clebert Suconic f18b4ee0c9 ARTEMIS-1287/ARTEMIS-1292 Complete Page on the Journal
fixing PagingTest.testDeletePhysicalPages
2017-07-14 15:04:45 -04:00
Clebert Suconic 3820ab8bb5 ARTEMIS-1284 Deleting a queue is not cleaning up page
This is fixing JMSPagingFileDeleteTest.testTopicsWithNonDurableSubscription
Issue introduced at 84e8a87325
2017-07-12 20:52:22 -04:00
Timothy Bish 22b8076b71 ARTEMIS-1283 Fix delay on drained response
On completion of drain the response is not flushed and the
client can wait a few seconds before another broker task
flushes the work.  Flush the connection after updating the
linked as being drained.  Also perform the work with the
connection lock held to prevent conccurent update of proton
state.
2017-07-12 19:20:01 -04:00
Clebert Suconic 3e48cd7787 ARTEMIS-1248 Fixing regression on Page.writing to live page
This is fixing ReplicatedPagedFailoverTest.testCommitOccurredUnblockedAndResendNoDuplicates
Even though the issue is not on replication.
2017-07-12 10:12:41 -04:00
Clebert Suconic 24d0a6c8fe ARTEMIS-1280 removing non used future 2017-07-11 15:10:53 -04:00
Francesco Nigro 4b943a745b ARTEMIS-1269 Improving Session Handling after replication changes
changes on ARTEMIS-1269 would have some implications on performance
this is to improve the packet handling.
2017-07-11 14:23:03 -04:00
Clebert Suconic 7fd17f407f ARTEMIS-1269 Simple Actor to replace certain executions
This is replacing an executor on ServerSessionPacketHandler
by a this actor.

This is to avoid creating a new runnable per packet received.

Instead of creating new Runnable, this will use a single static runnable
and the packet will be send by a message, which will be treated by a listener.

Look at ServerSessionPacketHandler on this commit for more information on how it works.
2017-07-11 14:22:36 -04:00
Clebert Suconic 82f071ff46 ARTEMIS-1280 Avoiding leak on Queue futures 2017-07-11 11:32:03 -04:00
Andy Taylor 9ad3ad4657 ARTEMIS-1277 - purgeOnNoConsumer is not working properly
make sure rollback doesn't add messages back

https://issues.apache.org/jira/browse/ARTEMIS-1277
2017-07-11 11:25:48 +01:00
Jiri Danek ad228e202f NO-JIRA: Addressing some deprecated usage on the codebase
- PROTOCOL_PROP_NAME
- ConnectionLifeCycleListener
- GENERIC_IGNORED_FILTER
- HttpHeaders.Names
- HttpHeaders.Names and similar
2017-07-10 14:06:07 -04:00
Martyn Taylor ce756d46f9 ARTEMIS-1271 FileSystemMonitor locking improvement 2017-07-07 13:58:53 -04:00
gtully d4150be0d9 ARTEMIS-1264 allow role mapping via chained login modules
Add krb5sslloginmodule that will populate userPrincipal that can be mapped to roles independently
Generalised callback handlers to take a connection and pull certs or peerprincipal based on
callback. This bubbled up into api change in securitystore and security manager
2017-07-06 23:41:02 -04:00
Clebert Suconic 89e84e1320 ARTEMIS-1269 Fixing blocked replication
If replication blocked anything on the journal
the processing from clients would be blocked
and nothing would work.

As part of this fix I am using an executor on ServerSessionPacketHandler
which will also scale better as the reader from Netty would be feed immediately.
2017-07-06 19:04:48 -04:00
gtully cda1e018e1 ARTEMIS-1264 Foundation work for authentication with Kerberos using KRB_ cypher suites.
Core client with netty connector and acceptor doing kerberos
jaas.doAs around sslengine init such that the SSL handshake can do kerberos ticket
generaton and validation.
The kerberos authenticated user is then validated with the security manager before
being populated into the message userId.
The feature is enabled with the kerb5Config property. When lowercase it is the
principal. With a leading uppercase char it is the login.config entry to use.
2017-07-06 11:30:25 -04:00
Clebert Suconic 387fca584e ARTEMIS-1269 replication won't finish synchronization 2017-07-01 00:48:33 -04:00
Francesco Nigro 7075e2e457 ARTEMIS-1266 Mapped Journal refactoring
The MAPPED journal refactoring include:
 - simplified lifecycle and logic (eg fixed file size with single mmap memory region)
 - supports for the TimedBuffer to coalesce msyncs (via Decorator pattern)
 - TLAB pooling of direct ByteBuffer like the NIO journal
 - remove of old benchmarks and benchmark dependencies
2017-06-30 16:17:19 +02:00
Howard Gao 06986e4ee1 ARTEMIS-1261 Adjust default confirmation-window-size for bridges
The default id-cache-size is 20000 and the default
confirmation-window-size is 1MB. It turns out the 1MB
size is too small for id-cache-size.

To fix it we adjust the confirmation-window-size to 10MB. Also
a test is added to guarantee it won't break this rule when this
default value is to be changed to any new value.
2017-06-29 12:56:16 -04:00
Howard Gao d50f577cd5 ARTEMIS-1221 Duplicated ID causes LargeMessage lost at backup
When a large message is replicated to backup, a pendingID is generated
when the large message is finished. This pendingID is generated by a
BatchingIDGenerator at backup.

It is possible that a pendingID generated at backup may be a duplicate
to an ID generated at live server.

This can cause a problem when a large message with a messageID that is
the same as another largemessage's pendingID is replicated and stored
in the backup's journal, and then a deleteRecord for the pendingID
is appended. If backup becomes live and loads the journal, it will
drop the large message add record because there is a deleteRecord of
the same ID (even though it is a pendingID of another message).
As a result the expecting client will never get this large message.

So in summary, the root cause is that the pendingIDs for large
messages are generated at backup while backup is not alive.

The solution to this is that instead of the backup generating
the pendingID, we make them all be generated in advance
at live server and let them replicated to backup whereever needed.
The ID generater at backup only works when backup becomes live
(when it is properly initialized from journal).
2017-06-29 00:03:47 +08:00
Francesco Nigro a8356fb057 ARTEMIS-1246 Fixing compatibility issue
It fixes compatibility issues with JMS Core clients using the old address model, allowing the client to query JMS temporary queues too.

you would eventually see this issue when using older clients:
AMQ119019: Queue already exists
2017-06-27 14:23:36 -04:00
Christopher L. Shannon (cshannon) a538b969c0 ARTEMIS-1258 - Add ServerSession as an argument to beforeSend and
afterSend
2017-06-27 12:42:40 -04:00
Clebert Suconic f407d86f0f ARTEMIS-1253 Fixing NetworkHealthCheck being shutdown after failures 2017-06-26 16:15:39 -04:00
Clebert Suconic 36110da9c8 ARTEMIS-1253 Refactoring renaming stop(boolean) to fail(boolean)
This method name would clash with ServiceComponent
As the real meaning here on this method is just to failover
So I've renamed the method to avoid the clash with my next commit

(I've done this on a separate commit as you may need to redo this
 commit from scratch again in other branches instead of lots of clashes on cherry-pick)
2017-06-26 16:15:39 -04:00
Howard Gao 045021f7df ARTEMIS-1220 Diverted LargeMessage file corrupted during replication
When a large message is being diverted, a new copy of the original
message is created and replicated (if there is a backup) to the backup.

In LargeServerMessageImpl.copy(long) it reuse a byte array to copy
message body. It is possible that one block of date is read into
the byte array before the previous read has been replicated,
causing the replicated bytes to corrupt.

If we make a copy of the byte array before replication, the corruption
of data will be avoided.
2017-06-26 14:31:43 -04:00
Martyn Taylor 222275dd8d ARTEMIS-1254 New OrderedExecutor for JDBC LargeMsg 2017-06-26 18:43:50 +01:00
Francesco Nigro 325f46e01f ARTEMIS-1248 Reduce garbage while Paging 2017-06-23 09:37:46 -04:00