Skip to content

Conversation

abhishek-sehgal954
Copy link
Contributor

#222
This is not the complete solution. Some refactoring, improvements and support in druid setup is pending. I wanted to get an initial feedback for this.

So I think there are 2 ways to do this.

  1. We create one more operator Pattern in which we give an option to user to select out of (1xx, 2xx, 3xx, 4xx, 5xx), so that we don't get unexpected patterns. This requires little frontend work.

  2. We implicitly support it from the backend like I have sort of done in this change. If a user passes 4xx, he/she will get response accordingly.

IMO both are okay, but intuitively would it make more sense to have an explicit operator so that user is sure and know exactly what he/she are searching.

Let me know your thoughts @ankitnayan

@pranay01 pranay01 requested a review from ankitnayan July 31, 2021 17:20
@pranay01 pranay01 added the query-service Regarding query service label Jul 31, 2021
@pranay01 pranay01 linked an issue Jul 31, 2021 that may be closed by this pull request
@ankitnayan
Copy link
Collaborator

ankitnayan commented Aug 1, 2021

@abhishek-sehgal954 I was thinking more like adding regex as an operator and using match(haystack, pattern) similar to what we have done for contains operator using ilike keyword in query at this code block

So users can apply generic regex operations to any of their tags.

@abhishek-sehgal954
Copy link
Contributor Author

@abhishek-sehgal954 I was thinking more like adding regex as an operator and using match(haystack, pattern) similar to what we have done for contains operator using ilike keyword in query at this code block

So users can apply generic regex operations to any of their tags.

okay, sounds good. will make the change.

@abhishek-sehgal954
Copy link
Contributor Author

@abhishek-sehgal954 I was thinking more like adding regex as an operator and using match(haystack, pattern) similar to what we have done for contains operator using ilike keyword in query at this code block

So users can apply generic regex operations to any of their tags.

@ankitnayan updated.

@ankitnayan
Copy link
Collaborator

ankitnayan commented Aug 2, 2021

@abhishek-sehgal954 seems fine. Below are a few checks for every PR

Let me know when these are done. We shall include it in checks also soon.

Also, I would change the PR to say something around regex pattern matching enabled for tags since it does more than just searching for status code pattern

@abhishek-sehgal954 abhishek-sehgal954 changed the title Allow users to search spans with status code pattern Filter spans using regex pattern matching in tags Aug 2, 2021
@abhishek-sehgal954
Copy link
Contributor Author

abhishek-sehgal954 commented Aug 2, 2021

@abhishek-sehgal954 seems fine. Below are a few checks for every PR

Let me know when these are done. We shall include it in checks also soon.

Also, I would change the PR to say something around regex pattern matching enabled for tags since it does more than just searching for status code pattern

@ankitnayan done.

@ankitnayan ankitnayan changed the title Filter spans using regex pattern matching in tags feat: Filter spans using regex pattern matching in tags Aug 2, 2021
@ankitnayan ankitnayan merged commit b5b0725 into SigNoz:main Aug 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
query-service Regarding query service
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4xx chart
3 participants