Re: H/A colocated replication environment not working as expected

2016-11-29 Thread grishezz
I only saw the  option available for shared-storage.
Can I somehow turn it on for replicated-colocated topology?



--
View this message in context: 
http://activemq.2283324.n4.nabble.com/H-A-colocated-replication-environment-not-working-as-expected-tp4719539p4719590.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Re: H/A colocated replication environment not working as expected

2016-11-29 Thread Justin Bertram
Sorry for the confusion.  The  option is only available 
for shared-storage.  The fail-over semantics for replication don't use that 
parameter.  Carry on.


Justin

- Original Message -
From: "grishezz" 
To: users@activemq.apache.org
Sent: Tuesday, November 29, 2016 4:01:55 PM
Subject: Re: H/A colocated replication environment not working as expected

I only saw the  option available for shared-storage.
Can I somehow turn it on for replicated-colocated topology?



--
View this message in context: 
http://activemq.2283324.n4.nabble.com/H-A-colocated-replication-environment-not-working-as-expected-tp4719539p4719590.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Re: H/A colocated replication environment not working as expected

2016-11-29 Thread andytaylor
you need to make sure that a backup is created colocated with server1 and
that it scales down.

On 29 November 2016 at 22:09, Justin Bertram-2 [via ActiveMQ] <
ml-node+s2283324n471959...@n4.nabble.com> wrote:

> Sorry for the confusion.  The  option is only
> available for shared-storage.  The fail-over semantics for replication
> don't use that parameter.  Carry on.
>
>
> Justin
>
> - Original Message -
> From: "grishezz" <[hidden email]
> >
> To: [hidden email] 
> Sent: Tuesday, November 29, 2016 4:01:55 PM
> Subject: Re: H/A colocated replication environment not working as expected
>
> I only saw the  option available for shared-storage.
> Can I somehow turn it on for replicated-colocated topology?
>
>
>
> --
> View this message in context: http://activemq.2283324.n4.
> nabble.com/H-A-colocated-replication-environment-not-working-as-expected-
> tp4719539p4719590.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>
>
> --
> If you reply to this email, your message will be added to the discussion
> below:
> http://activemq.2283324.n4.nabble.com/H-A-colocated-
> replication-environment-not-working-as-expected-tp4719539p4719591.html
> To start a new topic under ActiveMQ - User, email
> ml-node+s2283324n2341805...@n4.nabble.com
> To unsubscribe from ActiveMQ - User, click here
> 
> .
> NAML
> 
>




--
View this message in context: 
http://activemq.2283324.n4.nabble.com/H-A-colocated-replication-environment-not-working-as-expected-tp4719539p4719594.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: H/A colocated replication environment not working as expected

2016-11-29 Thread grishezz
What would be server2 in the topology I described? What configuration / which
actions do I need to take to make the messages stored on server1 (i.e. the
backup server colocated with server1) be available for consumption?



--
View this message in context: 
http://activemq.2283324.n4.nabble.com/H-A-colocated-replication-environment-not-working-as-expected-tp4719539p4719589.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


H/A colocated replication environment not working as expected

2016-11-29 Thread grishezz
Hello,

I am trying to set-up the following environment and have ran into
difficulties:

H/A cluster of 2 servers: server0 & server1 replication=colocated
master/slave, and message-load-balancing=OFF.

Running the following scenario:

1) start server0
2) start server1
3) start consumer0 (connected to server0)
4) start consumer1 (connected to server1)
5) start producer0 (connected to server0)
6) producer0 sends 100 messages to exampleQueue
7) consumer0 is blocked on the first message read using debugger
8) kill server0

Now, I expected these 100 messages that were not yet acknowledged to become
available on server1 (as server0 backup is supposed to be there). However
client1 is receiving no messages (and I can't see them via the jmx console
either - though here I wasn't sure if they should actually move to the live
exampleQueue on server1).

Below are the 2 logs and a configuration of one of the servers (the other is
an exact mirror image). I wonder if the "Connection failed with
failedOver=false" message might have something to do with the scenario not
working as expected. I have tried many different config permutations and
have gone through the documentation several times... I hope I am just
missing some minor detail.

Help would be greatly appreciated!


server0 log:

19:01:58,344 WARN  [org.apache.activemq.artemis.core.server] AMQ222018: AIO
was not located on this platform, it will fall back to using pure Java NIO.
If your platform is Linux, install LibAIO to enable the AIO journal
19:01:58,399 WARN  [org.apache.activemq.artemis.core.server] AMQ222018: AIO
was not located on this platform, it will fall back to using pure Java NIO.
If your platform is Linux, install LibAIO to enable the AIO journal
19:01:58,441 INFO  [org.apache.activemq.artemis.integration.bootstrap]
AMQ101000: Starting ActiveMQ Artemis Server
19:02:00,364 INFO  [org.apache.activemq.artemis.core.server] AMQ221000: live
Message Broker is starting with configuration Broker Configuration
(clustered=true,journalDirectory=C:\dev_temp\apache-artemis-1.5.0\examples\features\ha\mark-poc\target\server0\data/server0/data/messaging/journal,bindingsDirectory=C:\dev_temp\apache-artemis-1.5.0\examples\features\ha\mark-poc\target\server0\data/server0/data/messaging/bindings,largeMessagesDirectory=C:\dev_temp\apache-artemis-1.5.0\examples\features\ha\mark-poc\target\server0\data/server0/data/messaging/largemessages,pagingDirectory=C:\dev_temp\apache-artemis-1.5.0\examples\features\ha\mark-poc\target\server0\data/server0/data/messaging/paging)
19:02:00,391 INFO  [org.apache.activemq.artemis.core.server] AMQ221013:
Using NIO Journal
19:02:00,420 WARN  [org.apache.activemq.artemis.core.server] AMQ222007:
Security risk! Apache ActiveMQ Artemis is running with the default cluster
admin user and default password. Please see the cluster chapter in the
ActiveMQ Artemis User Guide for instructions on how to change this.
19:02:00,457 INFO  [org.apache.activemq.artemis.core.server] AMQ221043:
Protocol module found: [artemis-server]. Adding protocol support for: CORE
19:02:00,459 INFO  [org.apache.activemq.artemis.core.server] AMQ221043:
Protocol module found: [artemis-amqp-protocol]. Adding protocol support for:
AMQP
19:02:00,461 INFO  [org.apache.activemq.artemis.core.server] AMQ221043:
Protocol module found: [artemis-hornetq-protocol]. Adding protocol support
for: HORNETQ
19:02:00,463 INFO  [org.apache.activemq.artemis.core.server] AMQ221043:
Protocol module found: [artemis-mqtt-protocol]. Adding protocol support for:
MQTT
19:02:00,464 INFO  [org.apache.activemq.artemis.core.server] AMQ221043:
Protocol module found: [artemis-openwire-protocol]. Adding protocol support
for: OPENWIRE
19:02:00,465 INFO  [org.apache.activemq.artemis.core.server] AMQ221043:
Protocol module found: [artemis-stomp-protocol]. Adding protocol support
for: STOMP
19:02:00,737 INFO  [org.apache.activemq.artemis.core.server] AMQ221003:
Deploying queue jms.queue.exampleQueue
19:02:00,766 WARN  [org.apache.activemq.artemis.core.server] AMQ222165: No
Dead Letter Address configured for queue jms.queue.exampleQueue in
AddressSettings
19:02:00,767 WARN  [org.apache.activemq.artemis.core.server] AMQ222166: No
Expiry Address configured for queue jms.queue.exampleQueue in
AddressSettings
19:02:00,998 INFO  [org.apache.activemq.artemis.core.server] AMQ221020:
Started Acceptor at localhost:61616 for protocols
[CORE,MQTT,AMQP,HORNETQ,STOMP,OPENWIRE]
19:02:00,999 INFO  [org.apache.activemq.artemis.core.server] AMQ221007:
Server is now live
19:02:00,999 INFO  [org.apache.activemq.artemis.core.server] AMQ221001:
Apache ActiveMQ Artemis Message Broker version 1.5.0 [localhost,
nodeID=60b03b78-b58c-11e6-937d-b8a720524153] 
19:02:05,096 WARN  [org.apache.activemq.artemis.core.server] AMQ222165: No
Dead Letter Address configured for queue
sf.my-cluster.63157c62-b58c-11e6-ace0-b8a720524153 in AddressSettings
19:02:05,096 WARN  [org.apache.activemq.artemis.core.server] AMQ222166: No

Re: H/A colocated replication environment not working as expected

2016-11-29 Thread andytaylor
Im not 100% sure of your topology, however leaving backups out of it I
would expect to see 50 messages on server0 and 50 on server1 if you have
load balancing enabled.

On 29 November 2016 at 09:26, grishezz [via ActiveMQ] <
ml-node+s2283324n4719539...@n4.nabble.com> wrote:

> Hello,
>
> I am trying to set-up the following environment and have ran into
> difficulties:
>
> H/A cluster of 2 servers: server0 & server1 replication=colocated
> master/slave, and message-load-balancing=OFF.
>
> Running the following scenario:
>
> 1) start server0
> 2) start server1
> 3) start consumer0 (connected to server0)
> 4) start consumer1 (connected to server1)
> 5) start producer0 (connected to server0)
> 6) producer0 sends 100 messages to exampleQueue
> 7) consumer0 is blocked on the first message read using debugger
> 8) kill server0
>
> Now, I expected these 100 messages that were not yet acknowledged to
> become available on server1 (as server0 backup is supposed to be there).
> However client1 is receiving no messages (and I can't see them via the jmx
> console either - though here I wasn't sure if they should actually move to
> the live exampleQueue on server1).
>
> Below are the 2 logs and a configuration of one of the servers (the other
> is an exact mirror image). I wonder if the "Connection failed with
> failedOver=false" message might have something to do with the scenario not
> working as expected. I have tried many different config permutations and
> have gone through the documentation several times... I hope I am just
> missing some minor detail.
>
> Help would be greatly appreciated!
>
> 
> server0 log:
> 
> 19:01:58,344 WARN  [org.apache.activemq.artemis.core.server] AMQ222018:
> AIO was not located on this platform, it will fall back to using pure Java
> NIO. If your platform is Linux, install LibAIO to enable the AIO journal
> 19:01:58,399 WARN  [org.apache.activemq.artemis.core.server] AMQ222018:
> AIO was not located on this platform, it will fall back to using pure Java
> NIO. If your platform is Linux, install LibAIO to enable the AIO journal
> 19:01:58,441 INFO  [org.apache.activemq.artemis.integration.bootstrap]
> AMQ101000: Starting ActiveMQ Artemis Server
> 19:02:00,364 INFO  [org.apache.activemq.artemis.core.server] AMQ221000:
> live Message Broker is starting with configuration Broker Configuration
> (clustered=true,journalDirectory=C:\dev_temp\
> apache-artemis-1.5.0\examples\features\ha\mark-poc\target\
> server0\data/server0/data/messaging/journal,bindingsDirectory=C:\dev_temp\
> apache-artemis-1.5.0\examples\features\ha\mark-poc\target\
> server0\data/server0/data/messaging/bindings,
> largeMessagesDirectory=C:\dev_temp\apache-artemis-1.5.0\
> examples\features\ha\mark-poc\target\server0\data/server0/
> data/messaging/largemessages,pagingDirectory=C:\dev_temp\
> apache-artemis-1.5.0\examples\features\ha\mark-poc\target\
> server0\data/server0/data/messaging/paging)
> 19:02:00,391 INFO  [org.apache.activemq.artemis.core.server] AMQ221013:
> Using NIO Journal
> 19:02:00,420 WARN  [org.apache.activemq.artemis.core.server] AMQ222007:
> Security risk! Apache ActiveMQ Artemis is running with the default cluster
> admin user and default password. Please see the cluster chapter in the
> ActiveMQ Artemis User Guide for instructions on how to change this.
> 19:02:00,457 INFO  [org.apache.activemq.artemis.core.server] AMQ221043:
> Protocol module found: [artemis-server]. Adding protocol support for: CORE
> 19:02:00,459 INFO  [org.apache.activemq.artemis.core.server] AMQ221043:
> Protocol module found: [artemis-amqp-protocol]. Adding protocol support
> for: AMQP
> 19:02:00,461 INFO  [org.apache.activemq.artemis.core.server] AMQ221043:
> Protocol module found: [artemis-hornetq-protocol]. Adding protocol support
> for: HORNETQ
> 19:02:00,463 INFO  [org.apache.activemq.artemis.core.server] AMQ221043:
> Protocol module found: [artemis-mqtt-protocol]. Adding protocol support
> for: MQTT
> 19:02:00,464 INFO  [org.apache.activemq.artemis.core.server] AMQ221043:
> Protocol module found: [artemis-openwire-protocol]. Adding protocol support
> for: OPENWIRE
> 19:02:00,465 INFO  [org.apache.activemq.artemis.core.server] AMQ221043:
> Protocol module found: [artemis-stomp-protocol]. Adding protocol support
> for: STOMP
> 19:02:00,737 INFO  [org.apache.activemq.artemis.core.server] AMQ221003:
> Deploying queue jms.queue.exampleQueue
> 19:02:00,766 WARN  [org.apache.activemq.artemis.core.server] AMQ222165:
> No Dead Letter Address configured for queue jms.queue.exampleQueue in
> AddressSettings
> 19:02:00,767 WARN  [org.apache.activemq.artemis.core.server] AMQ222166:
> No Expiry Address configured for queue jms.queue.exampleQueue in
> AddressSettings
> 19:02:00,998 INFO  [org.apache.activemq.artemis.core.server] AMQ221020:
> Started Acceptor at localhost:61616 for protocols
> [CORE,MQTT,AMQP,HORNETQ,STOMP,OPENWIRE]
> 19:02:00,999 INFO  [org.apache.activemq.artemis.core.server] AMQ221007:
> 

Re: H/A colocated replication environment not working as expected

2016-11-29 Thread andytaylor
Then I would expect to see 100 messages at the broker you sent to and none
on the other live broker

On 29 November 2016 at 12:34, grishezz [via ActiveMQ] <
ml-node+s2283324n4719543...@n4.nabble.com> wrote:

> In this scenario message load balancing is disabled.
>
> --
> If you reply to this email, your message will be added to the discussion
> below:
> http://activemq.2283324.n4.nabble.com/H-A-colocated-
> replication-environment-not-working-as-expected-tp4719539p4719543.html
> To start a new topic under ActiveMQ - User, email
> ml-node+s2283324n2341805...@n4.nabble.com
> To unsubscribe from ActiveMQ - User, click here
> 
> .
> NAML
> 
>




--
View this message in context: 
http://activemq.2283324.n4.nabble.com/H-A-colocated-replication-environment-not-working-as-expected-tp4719539p4719544.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: H/A colocated replication environment not working as expected

2016-11-29 Thread grishezz
In this scenario message load balancing is disabled.



--
View this message in context: 
http://activemq.2283324.n4.nabble.com/H-A-colocated-replication-environment-not-working-as-expected-tp4719539p4719543.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Re: H/A colocated replication environment not working as expected

2016-11-29 Thread andytaylor
server0 is backed up by the backup server that is colocated with server1,
not server1 itself. Server2 can either be configured to start as an actual
live or scaledown to the live server, if the latter is configured you
should see the message in server1, if not they will be in the backup
started on server1 when it starts

On 29 November 2016 at 14:18, grishezz [via ActiveMQ] <
ml-node+s2283324n471954...@n4.nabble.com> wrote:

> Right. But now I kill server0 (with all 100 messages) before any messages
> were consumed. My expectation is for these messages to "migrate" to the
> other live server (server1), so that they could be consumed from there.
>
> I am saying "migrate", but really at this moment server0 is already dead,
> so what I thought is supposed to happen is for server1 to detect the
> failure of server0 and thus "restore" those 100 messages it was holding as
> a backup and make them available for consumption. Am I mistaken in this
> expectation?
>
> --
> If you reply to this email, your message will be added to the discussion
> below:
> http://activemq.2283324.n4.nabble.com/H-A-colocated-
> replication-environment-not-working-as-expected-tp4719539p4719546.html
> To start a new topic under ActiveMQ - User, email
> ml-node+s2283324n2341805...@n4.nabble.com
> To unsubscribe from ActiveMQ - User, click here
> 
> .
> NAML
> 
>




--
View this message in context: 
http://activemq.2283324.n4.nabble.com/H-A-colocated-replication-environment-not-working-as-expected-tp4719539p4719550.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: H/A colocated replication environment not working as expected

2016-11-29 Thread grishezz
Right. But now I kill server0 (with all 100 messages) before any messages
were consumed. My expectation is for these messages to "migrate" to the
other live server (server1), so that they could be consumed from there. 

I am saying "migrate", but really at this moment server0 is already dead, so
what I thought is supposed to happen is for server1 to detect the failure of
server0 and thus "restore" those 100 messages it was holding as a backup and
make them available for consumption. Am I mistaken in this expectation?



--
View this message in context: 
http://activemq.2283324.n4.nabble.com/H-A-colocated-replication-environment-not-working-as-expected-tp4719539p4719546.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Re: H/A colocated replication environment not working as expected

2016-11-29 Thread Justin Bertram
One more quick point...

Stopping a server gracefully (e.g. using CTRL-C) will not trigger fail-over 
unless  is true.  In general I recommend using a method 
like 'kill -9 ' to test fail-over.


Justin

- Original Message -
From: "andytaylor" 
To: users@activemq.apache.org
Sent: Tuesday, November 29, 2016 8:47:36 AM
Subject: Re: H/A colocated replication environment not working as expected

server0 is backed up by the backup server that is colocated with server1,
not server1 itself. Server2 can either be configured to start as an actual
live or scaledown to the live server, if the latter is configured you
should see the message in server1, if not they will be in the backup
started on server1 when it starts

On 29 November 2016 at 14:18, grishezz [via ActiveMQ] <
ml-node+s2283324n471954...@n4.nabble.com> wrote:

> Right. But now I kill server0 (with all 100 messages) before any messages
> were consumed. My expectation is for these messages to "migrate" to the
> other live server (server1), so that they could be consumed from there.
>
> I am saying "migrate", but really at this moment server0 is already dead,
> so what I thought is supposed to happen is for server1 to detect the
> failure of server0 and thus "restore" those 100 messages it was holding as
> a backup and make them available for consumption. Am I mistaken in this
> expectation?
>
> --
> If you reply to this email, your message will be added to the discussion
> below:
> http://activemq.2283324.n4.nabble.com/H-A-colocated-
> replication-environment-not-working-as-expected-tp4719539p4719546.html
> To start a new topic under ActiveMQ - User, email
> ml-node+s2283324n2341805...@n4.nabble.com
> To unsubscribe from ActiveMQ - User, click here
> 
> .
> NAML
> 
>




--
View this message in context: 
http://activemq.2283324.n4.nabble.com/H-A-colocated-replication-environment-not-working-as-expected-tp4719539p4719550.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.