ignite-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tolga HOŞGÖR <fasdfas...@gmail.com>
Subject How do I provide AffinityFunction.BackupFilter when mainly using C++ bindings
Date Thu, 13 Apr 2017 08:14:56 GMT

I am in a similar situation with the following unanswered SO question:

How can I achieve this? Quoting the question:

I am using the C++ bindings to have redundancy in my application. Alongside
the main C++ node, I am running a vanilla Java node via ignite.sh as a
backup on another node. I would like appoint this vanilla Java node to
always stay a *backup* node and never a primary node as long as there is a
C++ node running. Also, I need the C++ nodes to always stay as primary
nodes. A little data loss is acceptable with the PRIMARY_SYNC

My research led me to AffinityFunction.BackupFilter property to filter C++
nodes as primary. It seems that there is also some functions to give
*attributes* to nodes. So I guess I can set a specific attribute on C++
nodes and filter them to always stay as primary nodes.

However, C++ bindings apparently neither provide a way to set backup filter
nor allow setting attributes on the launched node. I have noticed some
modules get plugged through ignite-dir/libs but there is no tutorial about
that approach to add AffinityFunction. How can I achieve what I need? I
need to plug a custom affinity function while using C++ as the main and a
way to distinguish the C++ nodes.

View raw message