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

feat: add config switch to use cananry graph #2802

Merged
merged 1 commit into from
Oct 30, 2023

Conversation

gavinbarron
Copy link
Member

Closes #2761

PR Type

  • Feature

Description of the changes

Adds a config based mechanism to allow developers to target the canary deployment of graph for faster testing of changes related to mgt-chat which are in flight from AGS and/or workload teams

PR checklist

  • Project builds (yarn build) and changes have been tested in at least two supported browsers (Edge + non-Chromium based browser)
  • All public APIs (classes, methods, etc) have been documented following the jsdoc syntax
  • Stories have been added and existing stories have been tested
  • Added appropriate documentation. Docs PR:
  • License header has been added to all new source files (yarn setLicense)
  • Contains NO breaking changes

Other information

@gavinbarron gavinbarron requested a review from a team as a code owner October 26, 2023 21:31
@github-actions
Copy link

Code Coverage

Package Line Rate Branch Rate Complexity Health
mgt-chat.src.statefulClient 100% 100% 0
mgt-chat.src.utils 96% 88% 0
mgt-components.src.components.mgt-person 56% 47% 0
mgt-components.src.components.mgt-theme-toggle 100% 100% 0
mgt-components.src.components.sub-components.mgt-flyout 30% 13% 0
mgt-components.src.components.sub-components.mgt-spinner 100% 100% 0
mgt-components.src.graph 19% 7% 0
mgt-components.src.styles 96% 64% 0
mgt-components.src.utils 40% 4% 0
mgt-element.src 39% 0% 0
mgt-element.src.components 30% 0% 0
mgt-element.src.mock 51% 42% 0
mgt-element.src.providers 39% 19% 0
mgt-element.src.utils 43% 26% 0
Summary 40% (791 / 1969) 20% (245 / 1209) 0

@musale
Copy link
Contributor

musale commented Oct 27, 2023

@gavinbarron how do I switch to canary as a dev using the chat component? I'm having a challenge figuring out how to use the config.

@gavinbarron
Copy link
Member Author

good question, at the moment the way I've been doing it is to import GraphConfig into the index.tsx for the app and then set the config object GraphConfig.useCanary = true

it's nice and simple, for a bit more flexibility we could use an .env file to hold the value we want to use in index.tsx so it's swtichable at build time.

@gavinbarron gavinbarron linked an issue Oct 30, 2023 that may be closed by this pull request
@gavinbarron gavinbarron merged commit cb240cb into next/mgt-chat Oct 30, 2023
9 checks passed
@gavinbarron gavinbarron deleted the feat/canary-switch branch October 30, 2023 14:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[mgt-chat] Support for Canary tenants
2 participants