I have two SP nodes on different servers in HA cluster. I need to use distributing sinks, because both of nodes consumes events from EI, but passive node hold these events in queue. Active node send events to DB. I used @distribution annotation in tcp sink to distributing events from passive node to active node. Also I set forcePublish property to true, all as is described in documentation. https://docs.wso2.com/display/SP410/Minimum+High+Availability+%28HA%29+Deployment Now I have two problems.
- When one of node is down, the active node is still dropping events with this error: Dropping event at Sink 'tcp' at 'DistributionStream' as its still trying to reconnect! Why is there this error, if it's running in HA and one node is still up?
2.When both nodes are running, passive node still doesn't distribute events to active node, so only half of events are sended to DB, the second half still remainings on passive node and they are published only when passive node change state to active.
Distributor
Distributor.siddhi
@sink(type='tcp' , sync='true', @map(type='json'), @distribution(
forcePublish='true',
strategy='broadcast',
@destination(
url='tcp://x.x.x.0:7612/ExecutorSourceStream'),
@destination(
url='tcp://x.x.x.1:7612/ExecutorSourceStream')))
define stream DistributionStream(
test string
);
Executor
Executor.siddhi
@source(type='tcp', context='ExecutorSourceStream', @map(type='json'))
define stream ExecutorSourceStream(
test string
);
Deployment.yml on both nodes
siddhi:
extensions:
- extension:
name: tcp
namespace: source
properties:
host: 0.0.0.0
port: 7612
Any idea, what can be reason of theese problems?
Actually, it's solved refer to https://github.com/wso2/product-sp/issues/570