-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
[CDK] Always use lower cases for error message regex matching in error translation #44832
Conversation
The latest updates on your projects. Learn more about Vercel for Git βοΈ
|
@@ -145,7 +145,7 @@ open class ConnectorExceptionHandler { | |||
open fun translateConnectorSpecificErrorMessage(e: Throwable?): String? { | |||
if (e == null) return null | |||
for (error in connectorErrorDictionary) { | |||
if (e.message?.lowercase()?.matches(error.regexMatchingPattern.toRegex())!!) | |||
if (e.message?.lowercase()?.matches(error.regexMatchingPattern.lowercase().toRegex())!!) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rather than doing that, I'd rather store a pattern in the error object, and compile it with compilePattern(CASE_INSENSITIVE)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good idea! fixed, please take another look. thanks!
/publish-java-cdk force=true
|
What
Fixes #44439
Need to bump the certified connector to use it in the next.
Can this PR be safely reverted and rolled back?