FrankChen021 commented on PR #19514:
URL: https://github.com/apache/druid/pull/19514#issuecomment-4612684380

   > > I'm slightly concerned about the multiple interfaces and classes 
introduced in this PR, I wonder maybe we could just add `RegexMatcher` 
interface and just have two anonymous implementation from re2j and java. We 
could have another `FunctionalInterface` `RegexPattern` returns ` RegexMatcher` 
given a string, which can be used in `compiledPatternSupplier`.
   > > We could have a system wide default engine, but this could be override 
in `RegexInputFormat`.
   > 
   > Thanks @cecemei for input. @FrankChen021 Would you be also agree to 
refactor the current implementation to incorporate this?
   > 
   > About last point - We can add it later as separate PR - do not want to 
over complicate things here
   
   Thanks for submitting this PR. Indeed, the matcher and pattern interfaces 
confused me a little for the first glance of current implementation.
   
   The comment left by @cecemei makes it more intuitive for other developers to 
understand that the matcher interface is the main implementation of different 
pattern lib providers.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to