mkevo commented on a change in pull request #5159: URL: https://github.com/apache/geode/pull/5159#discussion_r433077472
########## File path: geode-core/src/main/java/org/apache/geode/internal/cache/RegionNameValidation.java ########## @@ -24,7 +24,7 @@ public class RegionNameValidation { - private static final Pattern NAME_PATTERN = Pattern.compile("[aA-zZ0-9-_.]+"); + private static final Pattern NAME_PATTERN = Pattern.compile("[a-zA-Z\\[\\]0-9-_.]+"); Review comment: I didn't find RFC for this, but old pattern include this characters and you can see it if you add logger for names in test `startingWithMatchingCharactersAreOk` in RegionNameValidationTest where it validates all characters which is allowed by this pattern. From ASCII table A is 65 and z is 122, and this part **A-z** include all characters between these two values, and this characters(^, `, [, ], and backslash) are between 91 and 96. Old pattern **[aA-zZ0-9-_.]+** is the same as **[A-z0-9-_.]+**.\ So we can go with change pattern to **[A-z0-9-_.]+** and be sure that if someone is using it we don't break them. And also document all charactes which is allowed. Do you agree with that? ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org