Closed pcmid closed 5 years ago
Thank you for your PR!
The current domain matching uses regex and le.com
will match google.com
indeed. However, it's possible to use regex metacharacter to create a custom pattern to match le.com
only.
I think it would be better to let people choose their own matching policy instead of simply replace the current regex implementation, and it would be nice if the current regex matching for domain and hosts could be faster.
Thank you for reply.
In my opinion, the matching speed is the most important. I have a list of 50,000 rows of domains. It is really too slow to use regular matching. So I submitted this pr. A more precise match is a side effect on this.
Shawn notifications@github.com 于2019年3月16日周六 下午10:14写道:
Thank you for your PR! The current domain matching uses regex, le.com will match google.com indeed. However, it's possible to use regex metacharacter to create a custom pattern to match le.com only.
I think it would be better to let people choose their own matching policy instead of simply replace the current regex implementation, and it would be nice if the current regex matching for domain and hosts could be faster.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/shawn1m/overture/pull/141#issuecomment-473533916, or mute the thread https://github.com/notifications/unsubscribe-auth/AYYCCVqr_Il-_l8SIh1lRdseelWuVYQqks5vXPxQgaJpZM4btbxU .
I suppose it's better to make those strategies both exist and let people choose their own way.
I will merge it sometime later after I found a proper solution.
Merged. Thanks!
When the domain file is large, the match will get faster and le.com will never match google.com again.