naah69 edited a comment on issue #5311:
URL: https://github.com/apache/skywalking/issues/5311#issuecomment-676970324


   sure, i guess that the error was caused by  `syncSend` ,there is no 
asyncSend in my application.but the error was throw by 
`org.apache.rocketmq.client.trace.AsyncTraceDispatcher$AsyncAppenderRequest`
   
   i use Aliyun Distributed Tracing to monitor my application.
   
   the application use [v8.1.0 of skywalking 
agent](https://www.apache.org/dyn/closer.cgi/skywalking/8.0.1/apache-skywalking-apm-8.0.1.tar.gz?spm=a2c4g.11186623.2.13.45b85968z5s9Z8&file=apache-skywalking-apm-8.0.1.tar.gz)
 to send info to Aliyun Distributed Tracing。
   
   ## myagent config:
   ```properties
   agent.service_name=seedserver
   agent.sample_n_per_3_secs=${SW_AGENT_SAMPLE:3}
   collector.backend_service=xxxxxxx
   agent.authentication=xxxxxxxxxxxxx
   logging.file_name=${SW_LOGGING_FILE_NAME:skywalking-api.log}
   logging.level=${SW_LOGGING_LEVEL:INFO}
   ```
   
   ## dependencies of spirngboot(jdk8):
   ```xml
     <parent>
           <groupId>org.springframework.boot</groupId>
           <artifactId>spring-boot-starter-parent</artifactId>
           <version>2.3.0.RELEASE</version>
       </parent>
   ```
   
   ## dependencies of myrocketmq:
   ```xml
           <dependency>
               <groupId>org.apache.rocketmq</groupId>
               <artifactId>rocketmq-spring-boot-starter</artifactId>
               <version>2.1.0</version>
               <exclusions>
                   <exclusion>
                       <artifactId>commons-codec</artifactId>
                       <groupId>commons-codec</groupId>
                   </exclusion>
                   <exclusion>
                       <artifactId>commons-collections</artifactId>
                       <groupId>commons-collections</groupId>
                   </exclusion>
                   <exclusion>
                       <artifactId>commons-lang3</artifactId>
                       <groupId>org.apache.commons</groupId>
                   </exclusion>
                   <exclusion>
                       <artifactId>commons-logging</artifactId>
                       <groupId>commons-logging</groupId>
                   </exclusion>
                   <exclusion>
                       <artifactId>fastjson</artifactId>
                       <groupId>com.alibaba</groupId>
                   </exclusion>
               </exclusions>
           </dependency>
   
   ```
   
   ## part code of rocketmq:
   ### yaml config:
   ```yaml
   rocketmq:
     name-server: http://xxxxxxx.cn-hangzhou.mq-internal.aliyuncs.com:8080
     producer:
       access-key: xxxxxxx
       secret-key: xxxxxxx
       group: GID_SEEDSERVER
     consumer:
       access-key: xxxxxxx
       secret-key: xxxxxxx
   ```
   
   ### consumer:
   ```java
   @Slf4j
   @Service
   @RocketMQMessageListener(
           topic = "SEEDSERVER_EXPORT",
           consumerGroup = "GID_SEEDSERVER_EXPORT_" + 
"${spring.profiles.active}",
           consumeTimeout = 24 * 60 * 60 * 1000,
           selectorType = SelectorType.TAG,
           selectorExpression = "${spring.profiles.active}"
   )
   ```
   
   ### provider:
   ```java
       @Autowired
       private RocketMQTemplate rocketMQTemplate;
       @Value("${spring.profiles.active}")
       private String profiles;
   
   //sync send
    rocketMQTemplate.syncSend("SEEDSERVER_EXPORT:" + profiles, 
JSON.toJSONString(message));
   ```


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