[GitHub] activemq-artemis issue #1856: ARTEMIS-853 Support for exclusive consumers
Github user michaelandrepearce commented on the issue: https://github.com/apache/activemq-artemis/pull/1856 @clebertsuconic as per your comment to look at an alternative QueueImpl with it having separate flow without counters for exclusive. IMO i don't think this is a better approach, but i want to offer it to you. There is an amount of logic that is almost similar but not re-usable or abstract-able (ive done what i could). This is why i followed the same logic that MessageGroups does when a group already is assigned, which is to override the consumer and then don't update the pos, as it made for a lot smaller change, less intrusive change following a pattern already done with msg groups. Anyhow if you prefer this then im not dead opposed to this approach just don't think its better, but i offer it for your review. ---
[GitHub] activemq-artemis pull request #1856: ARTEMIS-853 Support for exclusive consu...
GitHub user michaelandrepearce opened a pull request: https://github.com/apache/activemq-artemis/pull/1856 ARTEMIS-853 Support for exclusive consumers Alternative QueueImpl - Seperated logic without counters You can merge this pull request into a Git repository by running: $ git pull https://github.com/michaelandrepearce/activemq-artemis ARTEMIS-853-2 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/1856.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #1856 commit 87ecda7ed5b09774c23f3de16bff2b20971db015 Author: Michael André PearceDate: 2018-02-07T21:07:44Z ARTEMIS-853 Support for exclusive consumers Alternative QueueImpl - Seperated logic without counters ---
[GitHub] activemq-artemis pull request #1855: WIP - DONT MERGE
Github user michaelandrepearce closed the pull request at: https://github.com/apache/activemq-artemis/pull/1855 ---
[GitHub] activemq-artemis pull request #1855: WIP - DONT MERGE
GitHub user michaelandrepearce opened a pull request: https://github.com/apache/activemq-artemis/pull/1855 WIP - DONT MERGE You can merge this pull request into a Git repository by running: $ git pull https://github.com/michaelandrepearce/activemq-artemis Crazy Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/1855.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #1855 commit 7314453d66d7871503e8cd4e88245cfb32671652 Author: Michael André PearceDate: 2018-02-07T21:07:44Z WIP - DONT MERGE ---
[GitHub] activemq pull request #274: AMQ-6894: limit poison exception message to 1024
GitHub user ashakirin opened a pull request: https://github.com/apache/activemq/pull/274 AMQ-6894: limit poison exception message to 1024 AMQ-6894: Limit poison exception message to 1024 to avoid IOException be encoding You can merge this pull request into a Git repository by running: $ git pull https://github.com/ashakirin/activemq master Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq/pull/274.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #274 commit d0dab2e88b44702d26dd0883c9940b97ee03fdeb Author: Andrei ShakirinDate: 2018-02-07T18:28:55Z AMQ-6894: limit poison exception message to 1024 ---
[GitHub] activemq-artemis issue #1853: ARTEMIS-1663 - Add new message count and size ...
Github user cshannon commented on the issue: https://github.com/apache/activemq-artemis/pull/1853 Had to update the PR again as something got messed up when rebasing ---
[GitHub] activemq-artemis pull request #1853: ARTEMIS-1663 - Add new message count an...
Github user cshannon commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/1853#discussion_r166700570 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/impl/PageSubscriptionImpl.java --- @@ -439,7 +453,7 @@ public void confirmPosition(final Transaction tx, final PagePosition position) t public void ackTx(final Transaction tx, final PagedReference reference) throws Exception { confirmPosition(tx, reference.getPosition()); - counter.increment(tx, -1); + counter.increment(tx, -1, -getPersistentSize(reference)); --- End diff -- @michaelandrepearce - So because of this line here we can't really default the persistentSize to -1, it needs to be 0. This call here will store a new PageCountRecordInc() record to the journal with a negative count and negative size on message ack to decrement the counters. Because of this a negative can actually be a valid value and really 0 should mean not set (we should never have a message size of 0) ---
[GitHub] activemq-artemis issue #1853: ARTEMIS-1663 - Add new message count and size ...
Github user cshannon commented on the issue: https://github.com/apache/activemq-artemis/pull/1853 @clebertsuconic - I did some cleanup work and I added a couple of basic tests to the compatibility test. It doesn't do much but show that the current snapshot can load a 2.4 journal successfully (and it can load the paging store as well). We can expand the tests with more if you want. Also, I removed the persistentSize from the PageCountPendingImpl class as the size (and the count apparently) aren't actually used and not needed. On recovery we can recover the size from the paged reference. Do you think this is ready to merge? ---
[GitHub] activemq-artemis issue #1832: ARTEMIS-853 Support for exclusive consumers
Github user michaelandrepearce commented on the issue: https://github.com/apache/activemq-artemis/pull/1832 We do the same as if message group which doesnât increase the pos if itâs exclusive just like it doesnât if exclusive. We can enhance this if needed. Ping me on IRC tomorrow? happy to make further enhancements if needed. ---
[GitHub] activemq-artemis issue #1832: ARTEMIS-853 Support for exclusive consumers
Github user clebertsuconic commented on the issue: https://github.com/apache/activemq-artemis/pull/1832 @michaelandrepearce I think the logic should have been updated on QueueImpl for the exclusive consumer... You should just had the pos always 0. or have a different logic without using counters at all. The code became non consistent. the pos increases but then there is a statement to always get position 0 if exclusive. ---
Re: Thoughts on refactoring the ActiveMQ website
I'm sorry about the long delays in getting the official export from Confluence, but it took this long to get some resolution on the issue. I now have a full HTML export from Confluence with the exception of the Navigation page. You can grab the zip file of the HTML at the following URL: https://drive.google.com/file/d/1qoTC9KMw8oIzGWwBW1X-oDtZxt8mFZlX/view?usp=sharing Bruce On Wed, Feb 7, 2018 at 10:06 AM, Bruce Snyderwrote: > +1 > > Bruce > > On Sat, Feb 3, 2018 at 10:30 AM, Michael André Pearce < > michael.andre.pea...@me.com> wrote: > >> Hi All, >> >> It’s been a bit quiet on the front of this effort. >> >> I’d like to bump this a bit to get some feedback on the current examples, >> and try agree a plan going forwards and spread the work. >> >> I was speaking with Martyn the other week and we think maybe a brief >> webex to demo what’s been done so far and then discuss. >> Martyn’s offered he can host this using his bluejeans account (thanks) >> >> We are thinking of organising this for the week of 19th Feb. >> >> Any specific people who want to be involved can or cannot make? If not >> I’ll sync up with Martyn to agree and then post a time and date. >> >> Cheers >> Mike >> >> >> >> Sent from my iPhone >> >> > On 20 Dec 2017, at 01:26, Michael André Pearce < >> michael.andre.pea...@me.com> wrote: >> > >> > Just FYI have sent a PR with a link to my branch of this export now in >> a GitBook form still needs a lot of TLC but have tried to get a large bulk >> done. To provide some skeleton for 5.x documents. >> > >> > >> > Sent from my iPhone >> > >> >> On 18 Dec 2017, at 20:26, Michael André Pearce < >> michael.andre.pea...@me.com> wrote: >> >> >> >> Yeah, unfortunately the tool i found wanted just html it blew up when >> trying to use modified. >> >> >> >> Like wise there was a couple of pages it couldn’t convert due to a css >> file on import issue but this wasn’t that many. >> >> >> >> Sent from my iPhone >> >> >> >>> On 18 Dec 2017, at 19:15, Bruce Snyder >> wrote: >> >>> >> >>> Nice job, based on my spot check of a handful of files, it looks much >> >>> better. But we will still need to manually fix all the valid tables. >> >>> >> >>> Have you had a chance to look at the other branches that Dan Kulp >> provided? >> >>> >> >>> Bruce >> >>> >> >>> On Mon, Dec 18, 2017 at 10:59 AM, Michael André Pearce < >> >>> michael.andre.pea...@me.com> wrote: >> >>> >> I’ve had some luck auto generating MD files. >> >> Needs some cleanup which probably the worst can be bash scripted. >> >> Have sent a PR back to the activemq-web on github for others to see. >> >> Mike >> >> Sent from my iPhone >> >> > On 14 Dec 2017, at 16:31, Bruce Snyder >> wrote: >> > >> > Thanks, Dan. So far I only see the body.storage branch (the others >> should >> > propagate in time). But I see that it's already more comprehensive >> than >> the >> > HTML that I pushed because it contains all the directories. We >> should >> > probably wipe out the master branch and choose one of yours as the >> new >> > master branch. >> > >> > Bruce >> > >> >> On Thu, Dec 14, 2017 at 7:56 AM, Daniel Kulp >> wrote: >> >> >> >> >> >> I hacked the Confluence exporter a bit to grab the page content in >> >> different formats so we can see if one is easier to migrate or >> similar. I >> >> just pushed 3 new branches to this repo: >> >> >> >> body.only - this is basically the same HTML, but with all the >> “wrapper” >> >> stuff removed. Just the HTML of the body content. So no >> navigation >> or >> >> header/footer, etc… >> >> >> >> body.storage - this is the raw storage format of the data from >> >> confluence. Things like code snippets are in storage format >> >> (), etc. >> >> >> >> body.view - confluence has a “body.view” mode that is between the >> >> “storage” format and not really the exported HTML. The >> structured >> >> macros are expanded a bit
Re: Thoughts on refactoring the ActiveMQ website
+1 Bruce On Sat, Feb 3, 2018 at 10:30 AM, Michael André Pearce < michael.andre.pea...@me.com> wrote: > Hi All, > > It’s been a bit quiet on the front of this effort. > > I’d like to bump this a bit to get some feedback on the current examples, > and try agree a plan going forwards and spread the work. > > I was speaking with Martyn the other week and we think maybe a brief webex > to demo what’s been done so far and then discuss. > Martyn’s offered he can host this using his bluejeans account (thanks) > > We are thinking of organising this for the week of 19th Feb. > > Any specific people who want to be involved can or cannot make? If not > I’ll sync up with Martyn to agree and then post a time and date. > > Cheers > Mike > > > > Sent from my iPhone > > > On 20 Dec 2017, at 01:26, Michael André Pearce < > michael.andre.pea...@me.com> wrote: > > > > Just FYI have sent a PR with a link to my branch of this export now in a > GitBook form still needs a lot of TLC but have tried to get a large bulk > done. To provide some skeleton for 5.x documents. > > > > > > Sent from my iPhone > > > >> On 18 Dec 2017, at 20:26, Michael André Pearce < > michael.andre.pea...@me.com> wrote: > >> > >> Yeah, unfortunately the tool i found wanted just html it blew up when > trying to use modified. > >> > >> Like wise there was a couple of pages it couldn’t convert due to a css > file on import issue but this wasn’t that many. > >> > >> Sent from my iPhone > >> > >>> On 18 Dec 2017, at 19:15, Bruce Snyderwrote: > >>> > >>> Nice job, based on my spot check of a handful of files, it looks much > >>> better. But we will still need to manually fix all the valid tables. > >>> > >>> Have you had a chance to look at the other branches that Dan Kulp > provided? > >>> > >>> Bruce > >>> > >>> On Mon, Dec 18, 2017 at 10:59 AM, Michael André Pearce < > >>> michael.andre.pea...@me.com> wrote: > >>> > I’ve had some luck auto generating MD files. > > Needs some cleanup which probably the worst can be bash scripted. > > Have sent a PR back to the activemq-web on github for others to see. > > Mike > > Sent from my iPhone > > > On 14 Dec 2017, at 16:31, Bruce Snyder > wrote: > > > > Thanks, Dan. So far I only see the body.storage branch (the others > should > > propagate in time). But I see that it's already more comprehensive > than > the > > HTML that I pushed because it contains all the directories. We should > > probably wipe out the master branch and choose one of yours as the > new > > master branch. > > > > Bruce > > > >> On Thu, Dec 14, 2017 at 7:56 AM, Daniel Kulp > wrote: > >> > >> > >> I hacked the Confluence exporter a bit to grab the page content in > >> different formats so we can see if one is easier to migrate or > similar. I > >> just pushed 3 new branches to this repo: > >> > >> body.only - this is basically the same HTML, but with all the > “wrapper” > >> stuff removed. Just the HTML of the body content. So no > navigation > or > >> header/footer, etc… > >> > >> body.storage - this is the raw storage format of the data from > >> confluence. Things like code snippets are in storage format > >> (), etc. > >> > >> body.view - confluence has a “body.view” mode that is between the > >> “storage” format and not really the exported HTML. The > structured > >> macros are expanded a bit
[GitHub] activemq-artemis pull request #1832: ARTEMIS-853 Support for exclusive consu...
Github user asfgit closed the pull request at: https://github.com/apache/activemq-artemis/pull/1832 ---
[GitHub] activemq-artemis pull request #1854: [ARTEMIS-1666] List of prepared transac...
GitHub user yersan opened a pull request: https://github.com/apache/activemq-artemis/pull/1854 [ARTEMIS-1666] List of prepared transaction details returns Object.toString() instead of Json string Issue: https://issues.apache.org/jira/browse/ARTEMIS-1666 JBEAP Issue: https://issues.jboss.org/browse/JBEAP-14177 You can merge this pull request into a Git repository by running: $ git pull https://github.com/yersan/activemq-artemis bugs/ARTEMIS-1666 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/1854.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #1854 commit ecc13750929f7969c7cd36da357af7273a88f607 Author: Yeray BorgesDate: 2018-02-07T14:56:37Z [ARTEMIS-1666] List of prepared transaction details returns Object.toString() instead of Json string ---
[GitHub] activemq-artemis issue #1832: ARTEMIS-853 Support for exclusive consumers
Github user franz1981 commented on the issue: https://github.com/apache/activemq-artemis/pull/1832 @michaelandrepearce i don't have the chance to merge it yet :( Anyway it seems that there aren't any objections so I suppose it is ok ð ---
[GitHub] activemq-artemis pull request #1853: ARTEMIS-1663 - Add new message count an...
Github user clebertsuconic commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/1853#discussion_r166636796 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/codec/PageCountPendingImpl.java --- @@ -62,21 +67,41 @@ public long getPageID() { return pageID; } + /** +* @return the persistentSize +*/ + @Override + public long getPersistentSize() { + return persistentSize; + } + + /** +* @param persistentSize the persistentSize to set +*/ + public void setPersistentSize(long persistentSize) { + this.persistentSize = persistentSize; + } + @Override public int getEncodeSize() { - return DataConstants.SIZE_LONG * 2; + return DataConstants.SIZE_LONG * 3; } @Override public void encode(ActiveMQBuffer buffer) { buffer.writeLong(queueID); buffer.writeLong(pageID); + buffer.writeLong(persistentSize); --- End diff -- JournalCompatibilityTest under compatibility-tests. I don't think the test is using paging. we should just extend the test to use paging. I can help you with that if you have questions. ---
[GitHub] activemq-artemis pull request #1853: ARTEMIS-1663 - Add new message count an...
Github user cshannon commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/1853#discussion_r166632761 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/codec/PageCountPendingImpl.java --- @@ -62,21 +67,41 @@ public long getPageID() { return pageID; } + /** +* @return the persistentSize +*/ + @Override + public long getPersistentSize() { + return persistentSize; + } + + /** +* @param persistentSize the persistentSize to set +*/ + public void setPersistentSize(long persistentSize) { + this.persistentSize = persistentSize; + } + @Override public int getEncodeSize() { - return DataConstants.SIZE_LONG * 2; + return DataConstants.SIZE_LONG * 3; } @Override public void encode(ActiveMQBuffer buffer) { buffer.writeLong(queueID); buffer.writeLong(pageID); + buffer.writeLong(persistentSize); --- End diff -- I can add a compatibility test. The value will just be a default (@michaelandrepearce wants me to use -1 instead of 0 and i guess we just would ignore it if not set for the count). Where's the journal test located in the test suite? ---
[GitHub] activemq-artemis pull request #1853: ARTEMIS-1663 - Add new message count an...
Github user clebertsuconic commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/1853#discussion_r166630869 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/codec/PageCountPendingImpl.java --- @@ -62,21 +67,41 @@ public long getPageID() { return pageID; } + /** +* @return the persistentSize +*/ + @Override + public long getPersistentSize() { + return persistentSize; + } + + /** +* @param persistentSize the persistentSize to set +*/ + public void setPersistentSize(long persistentSize) { + this.persistentSize = persistentSize; + } + @Override public int getEncodeSize() { - return DataConstants.SIZE_LONG * 2; + return DataConstants.SIZE_LONG * 3; } @Override public void encode(ActiveMQBuffer buffer) { buffer.writeLong(queueID); buffer.writeLong(pageID); + buffer.writeLong(persistentSize); --- End diff -- OIC.. you already implemented it.. I would like to have a compatibility test validating that.. there's a journal test on the new compatibility testsuite already... but not one with paging.. and validating the counters... If you have a way to do it.. it would be great.. otherwise let me know and I will do it. ---
[GitHub] activemq-artemis pull request #1853: ARTEMIS-1663 - Add new message count an...
Github user cshannon commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/1853#discussion_r166630379 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/codec/PageCountPendingImpl.java --- @@ -62,21 +67,41 @@ public long getPageID() { return pageID; } + /** +* @return the persistentSize +*/ + @Override + public long getPersistentSize() { + return persistentSize; + } + + /** +* @param persistentSize the persistentSize to set +*/ + public void setPersistentSize(long persistentSize) { + this.persistentSize = persistentSize; + } + @Override public int getEncodeSize() { - return DataConstants.SIZE_LONG * 2; + return DataConstants.SIZE_LONG * 3; } @Override public void encode(ActiveMQBuffer buffer) { buffer.writeLong(queueID); buffer.writeLong(pageID); + buffer.writeLong(persistentSize); --- End diff -- @clebertsuconic - here is an example of where the size is now persisted ---
[GitHub] activemq-artemis issue #1853: ARTEMIS-1663 - Add new message count and size ...
Github user cshannon commented on the issue: https://github.com/apache/activemq-artemis/pull/1853 @clebertsuconic - The metric in the page counters is persisted along with the page counters now. When the page counters are written to the journal that metric is encoded to disk and reloaded on restart. Older versions of the journal are compatible, they will just not have that size value loaded as it won't have been saved previously. ---
[GitHub] activemq-artemis issue #1853: ARTEMIS-1663 - Add new message count and size ...
Github user clebertsuconic commented on the issue: https://github.com/apache/activemq-artemis/pull/1853 @cshannon although looking at the PR now you added persistent size into page counters... but as I read it, it is not persistent... We should go all the way in.. i.e... persist the new size metric along with the page counters... or all the way back.. i.e... only give user's paging metrics through page size... Implementing the counter on the journal is no big deal.. but I would like to keep it compatible... older versions of the journal should still be compatible. ---
Deadlock in ActiveMQ server between BrokerFilter and Producer creation with VM connection
Hi, I'm not if this topic should be posted in User forum or Dev one, as this issue is purely technical, i post it here. We have identified a potential "deadlock" between BrokerFilter and Producer creation with VM connection This block is random, it happened on one given machine but not the others. ActiveMQ version 5.9.0 Java version 1.8.0_111 Thread #310 : notified by BrokerFilter.addConsumer() and it creates a Producer with local VM connection Thread #308 : notifed by BrokerFilter.messageConsumed() and it tries to get Consumer info in our application with read lock Thread 380 : it is treating the Producer creation command but it's blocked by Thread #308 a lock inside held by ActiveMQ BrokerFilter stack. As this issue is not always happening, i guess it is related to the Threading model in ActiveMQ. And I would like to know in which case VM connection handling thread will be blocked by BrokerFilter and in which case it is not. Is it related to jvm arguments ? because the configuration of ActiveMQ is hard coded in our case. Thanks, zyc1984 "ActiveMQ Transport: tcp:///22.0.195.149:64315@64078" #310 daemon prio=5 os_prio=64 tid=0x00010274e000 nid=0x14d waiting on condition [0xfffe76ffd000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for <0xfffe8335fb60> (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039) at java.util.concurrent.ArrayBlockingQueue.take(ArrayBlockingQueue.java:403) at org.apache.activemq.transport.FutureResponse.getResult(FutureResponse.java:40) at org.apache.activemq.transport.ResponseCorrelator.request(ResponseCorrelator.java:87) at org.apache.activemq.ActiveMQConnection.syncSendPacket(ActiveMQConnection.java:1394) at org.apache.activemq.ActiveMQSession.syncSendPacket(ActiveMQSession.java:1925) at org.apache.activemq.ActiveMQMessageProducer.(ActiveMQMessageProducer.java:125) at org.apache.activemq.ActiveMQSession.createProducer(ActiveMQSession.java:969) at EventFeeder.start(GenericEventFeeder.java:63) at DefaultConsumerManager.startFeed(DefaultConsumerManager.java:192) at DefaultConsumerAdministration.consumerConnected(DefaultConsumerAdministration.java:249) at ConsumerListener.onConsumerConnect(ConsumerListener.java:31) at ActiveMQInterceptor.addConsumer(ActiveMQInterceptor.java:80) at org.apache.activemq.broker.MutableBrokerFilter.addConsumer(MutableBrokerFilter.java:102) at org.apache.activemq.broker.TransportConnection.processAddConsumer(TransportConnection.java:587) at org.apache.activemq.command.ConsumerInfo.visit(ConsumerInfo.java:347) at org.apache.activemq.broker.TransportConnection.service(TransportConnection.java:292) at org.apache.activemq.broker.TransportConnection$1.onCommand(TransportConnection.java:149) at org.apache.activemq.transport.MutexTransport.onCommand(MutexTransport.java:50) at org.apache.activemq.transport.WireFormatNegotiator.onCommand(WireFormatNegotiator.java:113) at org.apache.activemq.transport.AbstractInactivityMonitor.onCommand(AbstractInactivityMonitor.java:270) at org.apache.activemq.transport.TransportSupport.doConsume(TransportSupport.java:83) at org.apache.activemq.transport.tcp.TcpTransport.doRun(TcpTransport.java:214) at org.apache.activemq.transport.tcp.TcpTransport.run(TcpTransport.java:196) at java.lang.Thread.run(Thread.java:745) "ActiveMQ Transport: tcp:///22.0.195.149:64313@64078" #308 daemon prio=5 os_prio=64 tid=0x0001028d5000 nid=0x14b waiting on condition [0xfffe773fd000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for <0xfffe81003250> (a java.util.concurrent.locks.ReentrantReadWriteLock$NonfairSync) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) at java.util.concurrent.locks.AbstractQueuedSynchronizer.parkAndCheckInterrupt(AbstractQueuedSynchronizer.java:836) at java.util.concurrent.locks.AbstractQueuedSynchronizer.doAcquireShared(AbstractQueuedSynchronizer.java:967) at java.util.concurrent.locks.AbstractQueuedSynchronizer.acquireShared(AbstractQueuedSynchronizer.java:1283) at java.util.concurrent.locks.ReentrantReadWriteLock$ReadLock.lock(ReentrantReadWriteLock.java:727) at DefaultConsumerAdministration.consumed(DefaultConsumerAdministration.java:367) at ConsumerListener.onMessageConsumed(ConsumerListener.java:45) at ActiveMQInterceptor.messageConsumed(ActiveMQInterceptor.java:123) at
[GitHub] activemq-artemis issue #1853: ARTEMIS-1663 - Add new message count and size ...
Github user cshannon commented on the issue: https://github.com/apache/activemq-artemis/pull/1853 Oh ok I get it now. Yeah you are right that the PagingStore interface has a method to get the number of pages and the page size which can be used to get an idea of consumption. This value is exposed through AddressControl so users can see it. ---
[GitHub] activemq-artemis issue #1853: ARTEMIS-1663 - Add new message count and size ...
Github user clebertsuconic commented on the issue: https://github.com/apache/activemq-artemis/pull/1853 I was just saying paging metrics should be exposed. Even if the files are to be GCed but if something happened and they are not the user should have the metrics exposed about pages. I think we do have them but i donât remember now. Iâm away from a computer and I canât check now. ---
[GitHub] activemq-artemis issue #1853: ARTEMIS-1663 - Add new message count and size ...
Github user cshannon commented on the issue: https://github.com/apache/activemq-artemis/pull/1853 @clebertsuconic - I don't think we need to re-calculate anything if the values are missing for paging. The point of this metric isn't to give the user information on storage consumption as that data already exists. They can find out how many page files are being used and disk usage already, etc. The point of these metrics is to know exactly how much data on a queue is left to consume. So there might be a 5 megabyte page file but only 2 messages left to consume and the rest of the file is just waiting to be GC'd. This metric only includes the 2 messages to be consumed and not the rest of the file. ---
[GitHub] activemq-artemis issue #1853: ARTEMIS-1663 - Add new message count and size ...
Github user clebertsuconic commented on the issue: https://github.com/apache/activemq-artemis/pull/1853 I think paging should be measured just in number of pages (files) on the address. That would give users an idea about storage consumption. It wouldnât indeed be practical to load it to calculate sizes. ---
[GitHub] activemq-artemis pull request #1853: ARTEMIS-1663 - Add new message count an...
Github user cshannon commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/1853#discussion_r166601621 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/codec/PageCountRecordInc.java --- @@ -26,17 +26,20 @@ private int value; + private long persistentSize; --- End diff -- @michaelandrepearce - That is fine I will make those values -1, but I don't think we would try and re-calculate a correct value. When loading the journal you'd have to re-load the messages to calculate from the paging store which we don't want to do. I think the proper behavior is to just ignore it and not use the value in the calculations. Then over time as new records come in the values would be filled in and correct. If I change the value to -1 on the record, are you thinking we should just have the getter do the negative check and return 0 if it's -1 or were you thinking to just return -1 from the getter and then check for negative everywhere else the value is used? ---
[GitHub] activemq-artemis pull request #1853: ARTEMIS-1663 - Add new message count an...
Github user michaelandrepearce commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/1853#discussion_r166545869 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/codec/PageCountRecordInc.java --- @@ -26,17 +26,20 @@ private int value; + private long persistentSize; --- End diff -- Seems my comment is removed due to update. Should be -1. Reason for this is that if it isn't set e.g. have read up an old journal as such decode wont set it, and you know you need to calculate it to get a correct value. ---