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

control-service: fix graphql team filter not retrieveing special chars #863

Merged
merged 8 commits into from
Jun 21, 2022

Conversation

mrMoZ1
Copy link
Contributor

@mrMoZ1 mrMoZ1 commented Jun 14, 2022

why: users of control-service complained that graphQL API calls
for a team with special characters such as '(' don't yeild results
even though the team exists.

what: investigating the issue concluded that the team filter strategy
uses a regex method - String.matches("regex") string to
match the teams and would get the results tripped by special chars.

testing: added unit test.

Signed-off-by: Momchil Zhivkov mzhivkov@vmware.com

@gageorgiev
Copy link
Contributor

This entire issue begs the question, should special characters even be allowed in team names? IMO team names should be only comprised of lowercase letters and dashes, or more generally letters and a separator. Maybe we should discuss this more thoroughly.

@mrMoZ1
Copy link
Contributor Author

mrMoZ1 commented Jun 17, 2022

This entire issue begs the question, should special characters even be allowed in team names? IMO team names should be only comprised of lowercase letters and dashes, or more generally letters and a separator. Maybe we should discuss this more thoroughly.

Certainly something worth talking about, however we need to adopt this fix at least for the short term. As far as I was told team-service allows this and we are only following the convention.

@mrMoZ1 mrMoZ1 merged commit eb991a5 into main Jun 21, 2022
@mrMoZ1 mrMoZ1 deleted the person/mzhivkov/fix-search-by-team branch June 21, 2022 08:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants