Technoboy- commented on code in PR #21547:
URL: https://github.com/apache/pulsar/pull/21547#discussion_r1387461997


##########
pulsar-broker-common/src/main/java/org/apache/pulsar/broker/authentication/AuthenticationDataSource.java:
##########
@@ -153,4 +153,18 @@ default String getSubscription() {
      * Subscription name can be necessary for consumption.
      */
     default void setSubscription(String subscription) { };
+
+    /**
+     * Set a property.
+     * This property can be used post-authn or post-authz.
+     */
+    default void setProperty(String key, Object value) { };
+
+    /**
+     * Get a property.
+     * @return the match property by the key.
+     */
+    default Object getProperty(String key) {
+        return null;
+    }

Review Comment:
   > Throwing an exception like UnsupportedOperationException
   Should keep the same with other methods.
   
   



##########
pulsar-broker-common/src/main/java/org/apache/pulsar/broker/authentication/AuthenticationDataSource.java:
##########
@@ -153,4 +153,18 @@ default String getSubscription() {
      * Subscription name can be necessary for consumption.
      */
     default void setSubscription(String subscription) { };
+
+    /**
+     * Set a property.
+     * This property can be used post-authn or post-authz.
+     */
+    default void setProperty(String key, Object value) { };
+
+    /**
+     * Get a property.
+     * @return the match property by the key.
+     */
+    default Object getProperty(String key) {
+        return null;
+    }

Review Comment:
   > Throwing an exception like UnsupportedOperationException
   
   Should keep the same with other methods.
   
   



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