Skip to content

Conversation

@m-olko
Copy link
Contributor

@m-olko m-olko commented Oct 27, 2025

This PR

Removes deprecated bearerToken option from all references in code and in documentation. It also updates some tests, to use authHeader with Bearer type instead.

Related Issues

Fixes #1687

Notes

This may be breaking change, as it removes field from Sync struct. I updated all local tests and resources, but let me know if there are any other resources that are maintained by flagd community, that might create Sync struct with that field.

Signed-off-by: Marcin Olko <molko@google.com>
@m-olko m-olko requested review from a team as code owners October 27, 2025 10:37
@netlify
Copy link

netlify bot commented Oct 27, 2025

Deploy Preview for polite-licorice-3db33c ready!

Name Link
🔨 Latest commit 7871e16
🔍 Latest deploy log https://app.netlify.com/projects/polite-licorice-3db33c/deploys/6903856fc5d03100087dda93
😎 Deploy Preview https://deploy-preview-1816--polite-licorice-3db33c.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@dosubot dosubot bot added the size:L This PR changes 100-499 lines, ignoring generated files. label Oct 27, 2025
@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @m-olko, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request undertakes a significant refactor to remove the deprecated bearerToken configuration option, standardizing all HTTP synchronization authentication to use the more flexible authHeader field. This change simplifies the authentication mechanism by consolidating it into a single, comprehensive option, requiring users to adapt their configurations accordingly. The update impacts core synchronization logic, configuration parsing, and associated tests, ensuring a consistent and future-proof approach to authentication.

Highlights

  • Removal of Deprecated bearerToken Option: The bearerToken option has been completely removed from the codebase, including its definition in the Sync struct, configuration parsing logic, and usage in HTTP sync operations. This streamlines authentication to use the more generic authHeader field.
  • Standardization to authHeader: All authentication for HTTP syncs now exclusively relies on the authHeader field. This field allows for full control over the Authorization header, supporting various schemes like Bearer, Basic, etc., directly within the header value.
  • Updated Tests and Documentation: Existing test cases have been updated to reflect the removal of bearerToken and now utilize authHeader for authentication. The project documentation has also been revised to remove references to the deprecated bearerToken and guide users towards authHeader.
  • Potential Breaking Change: The removal of the bearerToken field from the Sync struct is a breaking change. Users who previously relied on bearerToken will need to update their configurations to use authHeader with the appropriate Bearer prefix.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request effectively removes the deprecated bearerToken option across the entire codebase. The changes are thorough, touching not only the core logic in http_sync.go and the SourceConfig struct, but also updating all relevant tests and documentation to reflect the removal. The migration to using authHeader is handled correctly, with examples and tests updated to show the new expected usage (e.g., authHeader: "Bearer <token>"). The PR correctly identifies this as a breaking change. The code quality is high, and the changes are clean and well-executed. No issues were found.

Copy link
Member

@aepfli aepfli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

Signed-off-by: m-olko <molko@google.com>
@sonarqubecloud
Copy link

@tangenti tangenti merged commit efda06a into open-feature:main Nov 3, 2025
18 checks passed
@github-actions github-actions bot mentioned this pull request Oct 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L This PR changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Remove deprecated bearerToken option

3 participants