yu199195 commented on a change in pull request #8429:
URL: https://github.com/apache/shardingsphere/pull/8429#discussion_r533048663



##########
File path: 
shardingsphere-agent/shardingsphere-agent-core/src/main/java/org/apache/shardingsphere/agent/core/plugin/PluginLoader.java
##########
@@ -62,18 +180,21 @@ public boolean containsType(final TypeDescription 
typeDescription) {
      * @return the plugin definition configurations.
      */
     public PluginAdviceDefine loadPluginAdviceDefine(final TypeDescription 
typeDescription) {
-        return null;
+        if (pluginDefineMap.containsKey(typeDescription.getTypeName())) {
+            return pluginDefineMap.get(typeDescription.getTypeName());
+        }
+        throw new AdviceNotFoundException();
     }
 
     /**
      * To get or create instance of the advice class. Create new one and 
caching when it is not exist.
      *
      * @param classNameOfAdvice the class name of advice
-     * @param <T> the advice type.
+     * @param <T>               the advice type.

Review comment:
       1 black 




----------------------------------------------------------------
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:
[email protected]


Reply via email to