[ 
https://issues.apache.org/jira/browse/IGNITE-9365?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16590829#comment-16590829
 ] 

David Harvey commented on IGNITE-9365:
--------------------------------------

I was thinking of adding new class along these lines, where the apply function 
will return true only if none of the node's attributes match those of any of 
the nodes in the list.   This would become part of the code base, but would 
only be used if configured as the backupAffinityFunction
 
ClusterNodeNoAttributesMatchBiPredicate implements 
IgniteBiPredicate<ClusterNode,List<ClusterNode>> {

 
    ClusterNodeNoAttributesMatchBiPredicate(String[] attributeNames)
    \{....}
 
For AvailabilityZones, there would be only one attribute examined, but we have 
some potential use cases for distributing backups across two sub-groups of an 
AZ.
 
Alternately, we could enhance the RendezvousAffinityFunction to allow one or 
more arbitrary attributes to be compared  to determine neighbors, rather  than 
only org.apache.ignite.macs, and to add a setting that controls whether backups 
should be placed on neighbors if they can't be placed anywhere else.  
 
If I have 2 backups and three availability zones (AZ), I want one copy of the 
data in each AZ.  If all nodes in one AZ fail, I want to be able to decide to 
try to get to three copies anyway, increasing the per node footprint by 50%, or 
to only run with one backup.     This would also give be a convoluted way to 
change  the number of backups of a cache dynamically:    Start the cache with a 
large number of backups, but don't provide a location where the backup would be 
allowed to run initially. 

> Force backups to different AWS availability zones using only Spring XML
> -----------------------------------------------------------------------
>
>                 Key: IGNITE-9365
>                 URL: https://issues.apache.org/jira/browse/IGNITE-9365
>             Project: Ignite
>          Issue Type: Improvement
>          Components: cache
>         Environment:  
>            Reporter: David Harvey
>            Assignee: David Harvey
>            Priority: Minor
>             Fix For: 2.7
>
>   Original Estimate: 168h
>  Remaining Estimate: 168h
>
> As a developer, I want to be able to force  cache backups each to a different 
> "Availability Zone", when I'm running out-of-the-box Ignite, without 
> additional Jars installed.  "Availability zone" is a AWS feature with 
> different names for the same function by other cloud providers.  A single 
> availability zone has the characteristic that some or all of the EC2 
> instances in that zone can fail together due to a single fault.   You have no 
> control over the hosts on which the EC2 instance VMs run on in AWS, except by 
> controlling the availability zone .  
>  
> I could write a few lines of a custom affinityBackupFilter, and configure it 
> a RendezvousAffinityFunction, but then I have to get it deployed on all nodes 
> in the cluster, and peer class loading will not work to this.   The code to 
> do this should just be part of Ignite. 
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to