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

xds/bootstrap: add plugin system for credentials specified in bootstrap file #5136

Merged
merged 26 commits into from Feb 1, 2022

Commits on Feb 1, 2022

  1. Support xDS credentials plugin.

    Currently the credentials used for communication with the xDS management
    server is restricted to "google_default" and "insecure". There is no way
    for users to inject custom credentials, even though the bootstrap can be
    used to pass in different values.
    
    This PR adds support for a new credentials package which can be used to
    register supported credentials along with a name that can be recognized
    by the bootstrap.
    
    The credential package also registers the currently supported
    "google_default" and "insecure" options to maintain the status quo. To keep the
    interface of the credentials builder clean, the insecure credentials now
    satisfies the grpc credentials bundle interface.
    anicr7 committed Feb 1, 2022
    Copy the full SHA
    6a1259c View commit details
    Browse the repository at this point in the history
  2. Copy the full SHA
    1e6e23b View commit details
    Browse the repository at this point in the history
  3. Copy the full SHA
    5f60e4b View commit details
    Browse the repository at this point in the history
  4. Use "Get" as the getter name to be consistent with current

    registry implementations.
    anicr7 committed Feb 1, 2022
    Copy the full SHA
    9808f0c View commit details
    Browse the repository at this point in the history
  5. Copy the full SHA
    b4f79bc View commit details
    Browse the repository at this point in the history
  6. Copy the full SHA
    116361c View commit details
    Browse the repository at this point in the history
  7. Move the credentials registry into bootstrap, delete previously added

    xds/credentials/*.go. Also add the relevant builders in the google creds
    package.
    anicr7 committed Feb 1, 2022
    Copy the full SHA
    da005ea View commit details
    Browse the repository at this point in the history
  8. Copy the full SHA
    3007940 View commit details
    Browse the repository at this point in the history
  9. Move the packages around for better organization as per the suggestions.

    1. New bootstrap package that users can use.
    2. Move insecure creds builder to google/creds.
    3. Move registration to google/ and google/insecure.
    anicr7 committed Feb 1, 2022
    Copy the full SHA
    497bec3 View commit details
    Browse the repository at this point in the history
  10. Don't export creds builders. Remove google/insecure and use

    credential/insecure instead.
    
    Don't use google/insecure in bootstrap.go as it leads to cyclic
    dependencies.
    anicr7 committed Feb 1, 2022
    Copy the full SHA
    1a5ce53 View commit details
    Browse the repository at this point in the history
  11. Copy the full SHA
    2a95e62 View commit details
    Browse the repository at this point in the history
  12. Copy the full SHA
    0c1de51 View commit details
    Browse the repository at this point in the history
  13. Copy the full SHA
    0251470 View commit details
    Browse the repository at this point in the history
  14. Copy the full SHA
    b132d05 View commit details
    Browse the repository at this point in the history
  15. Copy the full SHA
    c4dcabf View commit details
    Browse the repository at this point in the history
  16. Simplify unit tests

    anicr7 committed Feb 1, 2022
    Copy the full SHA
    e83cb32 View commit details
    Browse the repository at this point in the history
  17. Copy the full SHA
    f72d3db View commit details
    Browse the repository at this point in the history
  18. Address review comments.

    anicr7 committed Feb 1, 2022
    Copy the full SHA
    a7eae17 View commit details
    Browse the repository at this point in the history
  19. Copy the full SHA
    990f2f4 View commit details
    Browse the repository at this point in the history
  20. Use consts in unit tests

    anicr7 committed Feb 1, 2022
    Copy the full SHA
    362d1e0 View commit details
    Browse the repository at this point in the history
  21. Revert comments from creds back to credentials. Also change insecureB…

    …undle() to return new transport credentials again
    anicr7 committed Feb 1, 2022
    Copy the full SHA
    37ea507 View commit details
    Browse the repository at this point in the history
  22. Change log warning to returning an error instead, when building bundl…

    …e fails due to JSON parsing
    anicr7 committed Feb 1, 2022
    Copy the full SHA
    711c075 View commit details
    Browse the repository at this point in the history
  23. Copy the full SHA
    256872a View commit details
    Browse the repository at this point in the history
  24. Copy the full SHA
    1fa6ba1 View commit details
    Browse the repository at this point in the history
  25. Copy the full SHA
    7685e5f View commit details
    Browse the repository at this point in the history
  26. Copy the full SHA
    9895c8c View commit details
    Browse the repository at this point in the history