lordcheng10 commented on PR #17151:
URL: https://github.com/apache/pulsar/pull/17151#issuecomment-1250719360

   > I think that `containsInvisibleCharacters` is too limited. There might be 
other character classes that aren't suitable, so calling them "invisible" would 
be wrong.
   > 
   > Instead of checking for invalid characters, it would be better to have the 
check the validity of the given subscription name explicitly.
   > 
   > Pulsar already contains 
org.apache.pulsar.common.naming.NamedEntity#checkName method and a similar 
solution could be followed in this case. I guess switching to use 
NamedEntity.checkName could be a breaking change for existing applications. 
Adding a specific solution for Subscription name validation would be justified.
   > 
   > It should also be discussed whether there's a need for a feature flag for 
enforcing a stricter validation of the subscription name with 
NamedEntity.checkName so that there would be consistency across other named 
entitiies in Pulsar.
   
   @lhotari 
   1. Use org.apache.pulsar.common.naming.NamedEntity#checkName instead of 
containsInvisibleCharacters?
   2. Add a configuration flag to control whether to verify the subscription 
name?
   


-- 
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]

Reply via email to