wu-sheng commented on a change in pull request #6727:
URL: https://github.com/apache/skywalking/pull/6727#discussion_r620332923



##########
File path: 
oap-server/oal-rt/src/main/java/org/apache/skywalking/oal/rt/OALRuntime.java
##########
@@ -194,7 +196,13 @@ private void generateClassAtRuntime(OALScripts oalScripts) 
throws OALCompileExce
         }
 
         for (Map.Entry<String, DispatcherContext> entry : 
allDispatcherContext.getAllContext().entrySet()) {
-            dispatcherClasses.add(generateDispatcherClass(entry.getKey(), 
entry.getValue()));
+            final String fullClassName = dispatcherClassName(entry.getKey(), 
true);
+            if (DISPATCHER_CLASS_CACHE.containsKey(fullClassName)) {
+                continue;
+            }
+            final Class dispatcherClass = 
generateDispatcherClass(entry.getKey(), entry.getValue());
+            dispatcherClasses.add(dispatcherClass);
+            DISPATCHER_CLASS_CACHE.put(fullClassName, dispatcherClass);

Review comment:
       I think you should use OAL definition to separate the package names of 
the same ServiceDispatcher? Does this work?




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