- 
                Notifications
    You must be signed in to change notification settings 
- Fork 269
RC: Active-Active improvments #2299
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
          
     Merged
      
      
    
      
        
          +246
        
        
          −65
        
        
          
        
      
    
  
  
     Merged
                    Changes from all commits
      Commits
    
    
            Show all changes
          
          
            17 commits
          
        
        Select commit
          Hold shift + click to select a range
      
      c5ba13b
              
                checkpoint - getting rs content duplicated on rc
              
              
                cmilesb 07712e6
              
                generalize links
              
              
                cmilesb 344966f
              
                RC Active-Active section
              
              
                cmilesb acda1c4
              
                embeds
              
              
                cmilesb 1bbbd24
              
                show-on-path shortcode
              
              
                cmilesb f827241
              
                Fix relrefs
              
              
                cmilesb d2ea54b
              
                Debug info for show-on-path
              
              
                cmilesb f68d5c9
              
                Full filepath
              
              
                cmilesb 292cc91
              
                fix filepath error
              
              
                cmilesb c4eeeb3
              
                fix typo
              
              
                cmilesb 079c3fa
              
                more debugging
              
              
                cmilesb 228dd96
              
                change to .Path
              
              
                cmilesb 2f630c9
              
                More debugging
              
              
                cmilesb 6b33ee8
              
                Remove show-on-path shortcode
              
              
                cmilesb c9040e2
              
                Manage regions page
              
              
                cmilesb 954c47f
              
                Apply suggestions from code review
              
              
                cmilesb 5baa0a8
              
                suggestions
              
              
                cmilesb File filter
Filter by extension
Conversations
          Failed to load comments.   
        
        
          
      Loading
        
  Jump to
        
          Jump to file
        
      
      
          Failed to load files.   
        
        
          
      Loading
        
  Diff view
Diff view
There are no files selected for viewing
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              | Original file line number | Diff line number | Diff line change | 
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| Every CIDR should be unique to properly route network traffic between each Active-Active database instance and your consumer VPCs. The CIDR block regions should _not_ overlap between the Redis server and your app consumer VPCs. In addition, CIDR blocks should not overlap between cluster instances. | ||
|  | ||
| When all **Deployment CIDR** regions display a green checkmark, you're ready to continue. | ||
|  | ||
| {{<image filename="images/rc/icon-cidr-address-ok.png" width="30px" alt="Green checkmarks indicate valid CIDR address values." >}} | ||
|  | ||
| Red exclamation marks indicate error conditions; the tooltip provides additional details. | ||
|  | ||
| {{<image filename="images/rc/icon-cidr-address-error.png" width="30px" alt="Red exclamation points indicate CIDR address problems." >}} | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              | Original file line number | Diff line number | Diff line change | 
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| In the example below, database writes are concurrent at the points in | ||
| time t1 and t2 and happen before a sync can communicate the changes. | ||
| However, writes at times t4 and t6 are not concurrent as a sync happened | ||
| in between. | ||
|  | ||
| | **Time** | **CRDB Instance1** | **CRDB Instance2** | | ||
| | ------: | :------: | :------: | | ||
| | t1 | SET key1 "a" | | | ||
| | t2 | | SET key1 "b" | | ||
| | t3 | — Sync — | — Sync — | | ||
| | t4 | SET key1 "c" | | | ||
| | t5 | — Sync — | — Sync — | | ||
| | t6 | | SET key1 "d" | | ||
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
        
          
          
            10 changes: 7 additions & 3 deletions
          
          10 
        
  ...ases/configuration/active-active-redis.md → ...rate/rc/databases/active-active/_index.md
  
  
      
      
   
        
      
      
    
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              
        
          
          
            52 changes: 52 additions & 0 deletions
          
          52 
        
  content/operate/rc/databases/active-active/develop/_index.md
  
  
      
      
   
        
      
      
    
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
              | Original file line number | Diff line number | Diff line change | 
|---|---|---|
| @@ -0,0 +1,52 @@ | ||
| --- | ||
| Title: Active-Active Redis applications | ||
| alwaysopen: false | ||
| categories: | ||
| - docs | ||
| - operate | ||
| - rc | ||
| description: General information to keep in mind while developing applications for | ||
| an Active-Active database. | ||
| hideListLinks: true | ||
| linktitle: Develop applications | ||
| weight: 99 | ||
| note: The rest of the content in this folder is mounted from content/operate/rs/databases/active-active/develop. If you need to make a change in the pages in this folder, make it in the RS folder. | ||
| --- | ||
| Developing globally distributed applications can be challenging, as | ||
| developers have to think about race conditions and complex combinations | ||
| of events under geo-failovers and cross-region write conflicts. In Redis Cloud, Active-Active databases | ||
| simplify developing such applications by directly using built-in smarts | ||
| for handling conflicting writes based on the data type in use. Instead | ||
| of depending on just simplistic "last-writer-wins" type conflict | ||
| resolution, geo-distributed Active-Active databases combine techniques defined in CRDT | ||
| (conflict-free replicated data types) research with Redis types to | ||
| provide smart and automatic conflict resolution based on the data type's | ||
| intent. | ||
|  | ||
| An Active-Active database is a globally distributed database that spans multiple cloud provider regions. Each Active-Active database can have many Active-Active database instances | ||
| that come with added smarts for handling globally distributed writes | ||
| using the proven | ||
| [CRDT](https://en.wikipedia.org/wiki/Conflict-free_replicated_data_type) | ||
| approach. | ||
| [CRDT](https://en.wikipedia.org/wiki/Conflict-free_replicated_data_type) | ||
| research describes a set of techniques for creating systems that can | ||
| handle conflicting writes. CRDBs powered by Multi-Master Replication | ||
| (MMR) provide a straightforward and effective way to replicate your | ||
| data between regions and simplify development of complex applications | ||
| that can maintain correctness under geo-failovers and concurrent | ||
| cross-region writes to the same data. | ||
|  | ||
| {{< image filename="/images/rs/crdbs.png" alt="Geo-replication world map">}} | ||
|  | ||
| Active-Active databases replicate data between multiple Redis Cloud provider regions. Common uses for Active-Active databases include disaster recovery, | ||
| geographically redundant applications, and keeping data closer to your | ||
| users' locations. MMR is always multi-directional amongst the regions | ||
| configured in the Active-Active database. For unidirectional replication, see [Active-Passive replication]({{< relref "/operate/rc/databases/migrate-databases#sync-using-active-passive" >}}). | ||
|  | ||
| ## Example of synchronization | ||
|  | ||
| {{< embed-md "rc-rs-aa-synchronization.md" >}} | ||
|  | ||
| [Learn more about | ||
| synchronization for | ||
| each supported data type]({{< relref "/operate/rc/databases/active-active/develop/data-types/" >}}) and [how to develop applications]({{< relref "/operate/rc/databases/active-active/develop/develop-for-aa" >}}) with them on Redis Cloud. | 
      
      Oops, something went wrong.
        
    
  
  Add this suggestion to a batch that can be applied as a single commit.
  This suggestion is invalid because no changes were made to the code.
  Suggestions cannot be applied while the pull request is closed.
  Suggestions cannot be applied while viewing a subset of changes.
  Only one suggestion per line can be applied in a batch.
  Add this suggestion to a batch that can be applied as a single commit.
  Applying suggestions on deleted lines is not supported.
  You must change the existing code in this line in order to create a valid suggestion.
  Outdated suggestions cannot be applied.
  This suggestion has been applied or marked resolved.
  Suggestions cannot be applied from pending reviews.
  Suggestions cannot be applied on multi-line comments.
  Suggestions cannot be applied while the pull request is queued to merge.
  Suggestion cannot be applied right now. Please check back later.
  
    
  
    
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a thought - do you think this might work well as a sequence diagram?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably. I don't want to make that change without buy-in from @rrelledge since this appears in both the Redis Cloud and Redis Software docs, and might be slightly out of scope for this PR specifically.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sequence diagrams probably would be better than the current (very old) tables, but I think maybe that could be handled in a separate ticket/PR so that it doesn't block merging this one.