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

Change adaptive sample groups to use Globs #1053

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

SimunKaracic
Copy link
Contributor

No description provided.

@@ -275,7 +274,7 @@ object AdaptiveSampler {

Settings.Group(
name = groupName,
operations = groupConfig.getStringList("operations").asScala.toSeq,
operations = groupConfig.getStringList("operations").asScala.toSeq.map(Filter.fromGlob),
Copy link
Contributor

Choose a reason for hiding this comment

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

Don't like this, for two reasons:

  1. We should allow people to use regular expressions, if they want to
  2. This is not backwards compatible! We know some people have already set it up to raw strings.

What I suggest we do is:

  1. Copy logic from
    def fromGlob(glob: String): Filter =
  2. Change it so that the default is not glob, but it's exact match (a new type of filter, I guess, Filter.StringMatch or something)
  3. Immediately announce exact match as deprecated
  4. Move to default-to-glob in the next minor version (2.3.0, I guess)

Thoughts, @SimunKaracic , @ivantopo?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Assuming you mean this under 1.

private def readMatcher(pattern: String): Filter.Matcher = {

That all sounds like a great idea

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.

2 participants