Skip to content
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

Multi-tenant migrations: add topo locking while updating keyspace routing rules #15807

Merged

Commits on May 5, 2024

  1. Add keyspace routing rules lock. Use it while updating rules

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 5, 2024
    Configuration menu
    Copy the full SHA
    d716243 View commit details
    Browse the repository at this point in the history
  2. More tests. Refactor

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 5, 2024
    Configuration menu
    Copy the full SHA
    bc1512d View commit details
    Browse the repository at this point in the history
  3. Fix locking logic and related tests

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 5, 2024
    Configuration menu
    Copy the full SHA
    f5ae07c View commit details
    Browse the repository at this point in the history
  4. Refactor topo lock, remove unnecessary stuff

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 5, 2024
    Configuration menu
    Copy the full SHA
    50cc2b6 View commit details
    Browse the repository at this point in the history
  5. More cleanup

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 5, 2024
    Configuration menu
    Copy the full SHA
    0c935d6 View commit details
    Browse the repository at this point in the history
  6. Single entry point for serializing all functionalities updating keysp…

    …ace routing rules
    
    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 5, 2024
    Configuration menu
    Copy the full SHA
    254aa1d View commit details
    Browse the repository at this point in the history
  7. Delete keyspace routing rules on Cancel

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 5, 2024
    Configuration menu
    Copy the full SHA
    cc8b452 View commit details
    Browse the repository at this point in the history
  8. Add test to confirm that concurrent updates don't overwrite each other

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 5, 2024
    Configuration menu
    Copy the full SHA
    6f711b1 View commit details
    Browse the repository at this point in the history
  9. Update reasons for generic locking

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 5, 2024
    Configuration menu
    Copy the full SHA
    a3b761f View commit details
    Browse the repository at this point in the history
  10. Reformat exports

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 5, 2024
    Configuration menu
    Copy the full SHA
    5f1e8ec View commit details
    Browse the repository at this point in the history
  11. Add concurrency tests for a specific topo to confirm that it works fo…

    …r a 'real' topo implementation in addition to memtopo
    
    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 5, 2024
    Configuration menu
    Copy the full SHA
    682b00c View commit details
    Browse the repository at this point in the history
  12. Address review comments. Change the key paths where rules and locks a…

    …re created
    
    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 5, 2024
    Configuration menu
    Copy the full SHA
    5e27c79 View commit details
    Browse the repository at this point in the history
  13. Modify comments/logs to reflect the sentinel nomenclature

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 5, 2024
    Configuration menu
    Copy the full SHA
    8047f35 View commit details
    Browse the repository at this point in the history

Commits on May 6, 2024

  1. Playing with some ideas

    Signed-off-by: Matt Lord <mattalord@gmail.com>
    mattlord committed May 6, 2024
    Configuration menu
    Copy the full SHA
    f639c60 View commit details
    Browse the repository at this point in the history
  2. Fix unit tests

    Signed-off-by: Matt Lord <mattalord@gmail.com>
    mattlord committed May 6, 2024
    Configuration menu
    Copy the full SHA
    6119992 View commit details
    Browse the repository at this point in the history
  3. Still working on tests

    Signed-off-by: Matt Lord <mattalord@gmail.com>
    mattlord committed May 6, 2024
    Configuration menu
    Copy the full SHA
    23dc487 View commit details
    Browse the repository at this point in the history
  4. Revert matt's testing / investigation work

    This reverts commit 23dc487.
    This reverts commit 6119992.
    This reverts commit f639c60.
    
    Signed-off-by: Matt Lord <mattalord@gmail.com>
    mattlord committed May 6, 2024
    Configuration menu
    Copy the full SHA
    b0aef45 View commit details
    Browse the repository at this point in the history

Commits on May 8, 2024

  1. Address review comment: Remove space from name

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 8, 2024
    Configuration menu
    Copy the full SHA
    70b59d4 View commit details
    Browse the repository at this point in the history
  2. Address review comment: remove export of global cell. Move key creati…

    …on logic to topo server
    
    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 8, 2024
    Configuration menu
    Copy the full SHA
    74e16ed View commit details
    Browse the repository at this point in the history
  3. Address Review Comment: rename updateKeyspaceRoutingRule to updateKey…

    …spaceRoutingRules
    
    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 8, 2024
    Configuration menu
    Copy the full SHA
    506475f View commit details
    Browse the repository at this point in the history
  4. Change the mechanism of updating keyspace routing rules under the loc…

    …k for MoveTables actions. ApplyKeyspaceRoutingRules has been commented out temporarily
    
    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 8, 2024
    Configuration menu
    Copy the full SHA
    c993e8c View commit details
    Browse the repository at this point in the history

Commits on May 9, 2024

  1. Change topo paths for keyspace routing rules

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 9, 2024
    Configuration menu
    Copy the full SHA
    7b90ed6 View commit details
    Browse the repository at this point in the history
  2. Change ApplyKeyspaceRoutingRules to return current and new rules. Add…

    … e2e test for it
    
    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 9, 2024
    Configuration menu
    Copy the full SHA
    6452e4c View commit details
    Browse the repository at this point in the history

Commits on May 10, 2024

  1. Minor refactor of cli command

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 10, 2024
    Configuration menu
    Copy the full SHA
    de3b3e9 View commit details
    Browse the repository at this point in the history
  2. Minor refactor

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 10, 2024
    Configuration menu
    Copy the full SHA
    309f594 View commit details
    Browse the repository at this point in the history
  3. Add tests for krr

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 10, 2024
    Configuration menu
    Copy the full SHA
    5ecdafc View commit details
    Browse the repository at this point in the history
  4. Confirm that we hold the lock while saving keyspace routing rules. Ad…

    …d test. Some additional comments
    
    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 10, 2024
    Configuration menu
    Copy the full SHA
    a9c4574 View commit details
    Browse the repository at this point in the history
  5. Delete map better!

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 10, 2024
    Configuration menu
    Copy the full SHA
    461a0b6 View commit details
    Browse the repository at this point in the history

Commits on May 11, 2024

  1. Move setting response parameters to the vtctld server instead of on t…

    …he client side
    
    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 11, 2024
    Configuration menu
    Copy the full SHA
    f483725 View commit details
    Browse the repository at this point in the history

Commits on May 13, 2024

  1. My suggestions

    Signed-off-by: Matt Lord <mattalord@gmail.com>
    mattlord committed May 13, 2024
    Configuration menu
    Copy the full SHA
    8a22e7e View commit details
    Browse the repository at this point in the history
  2. Don't send old rules on ApplyKeyspaceRoutingRules

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 13, 2024
    Configuration menu
    Copy the full SHA
    7f59799 View commit details
    Browse the repository at this point in the history
  3. Merge remote-tracking branch 'planetscale/rohit/multi-tenant-routing-…

    …rules-locking' into rohit/multi-tenant-routing-rules-locking
    
    Signed-off-by: Matt Lord <mattalord@gmail.com>
    mattlord committed May 13, 2024
    Configuration menu
    Copy the full SHA
    a696c1e View commit details
    Browse the repository at this point in the history
  4. Post merge fixups

    Signed-off-by: Matt Lord <mattalord@gmail.com>
    mattlord committed May 13, 2024
    Configuration menu
    Copy the full SHA
    3b08add View commit details
    Browse the repository at this point in the history
  5. Another minor cleanup after merge + review

    Signed-off-by: Matt Lord <mattalord@gmail.com>
    mattlord committed May 13, 2024
    Configuration menu
    Copy the full SHA
    0c84ec1 View commit details
    Browse the repository at this point in the history

Commits on May 14, 2024

  1. Try to deflake unit test when code coverage is enabled

    Signed-off-by: Matt Lord <mattalord@gmail.com>
    mattlord committed May 14, 2024
    Configuration menu
    Copy the full SHA
    e65f861 View commit details
    Browse the repository at this point in the history
  2. Skip TestConcurrentKeyspaceRoutingRulesUpdates in code coverage mode

    Signed-off-by: Rohit Nayak <rohit@planetscale.com>
    rohit-nayak-ps committed May 14, 2024
    Configuration menu
    Copy the full SHA
    c468c8d View commit details
    Browse the repository at this point in the history