Rainlone opened a new issue, #3323:
URL: https://github.com/apache/servicecomb-java-chassis/issues/3323

   这个类有构造这个代码:
   org.apache.servicecomb.swagger.invocation.SwaggerInvocation#SwaggerInvocation
     public SwaggerInvocation() {
       parentContext = ContextUtils.getInvocationContext();
       if (parentContext != null) {
         addContext(parentContext.getContext());
         addLocalContext(parentContext.getLocalContext());
       }
     }
   
   其中addLocalContext(parentContext.getLocalContext()); 
里面调用了localContext.putAll(otherContext);
   这个在多线程环境,业务代码自己开多线程调用下游服务传递上下文会有多线程问题,报Concurrentmodificationexception异常
   建议使用public void setLocalContext(Map<String, Object> localContext)直接设置上下文


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