You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by GitBox <gi...@apache.org> on 2019/12/11 01:49:16 UTC

[GitHub] [skywalking] cyejing commented on a change in pull request #4015: add operation name in async method

cyejing commented on a change in pull request #4015: add operation name in async method
URL: https://github.com/apache/skywalking/pull/4015#discussion_r356368716
 
 

 ##########
 File path: apm-sniffer/apm-agent-core/src/main/java/org/apache/skywalking/apm/agent/core/context/trace/EntrySpan.java
 ##########
 @@ -96,6 +96,9 @@ public AbstractTracingSpan setComponent(String componentName) {
 
     @Override
     public AbstractTracingSpan setOperationName(String operationName) {
+        if (isInAsyncMode) {
+            throw new RuntimeException("Span is in async mode, Should use setOperationNameInAsync method");
 
 Review comment:
   Isn't it necessary to add ``setOperationNameInAsync``,  judging from this place is async mode, and modify ``operationName``,Isn't this better, only one api

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services