codingapi / tx-lcn

LCN distributed transaction framework, compatible with dubbo, spring cloud and Motan framework, supports various relational databases
https://www.codingapi.com
Apache License 2.0
4.22k stars 1.46k forks source link

tx-lcn 5.0.2.RELEASE版本不支持RestTemplate这种形式调用接口吗,我测试这种形式调用接口的时候发生错误时不会回滚 #446

Open yahuishi opened 5 years ago

yahuishi commented 5 years ago

1. Bug Description

2. Environment:

3. Exception Stacktrace

Paste your Exception Stacktrace here!

4. Tour Idea

hairongwang commented 5 years ago

解决了吗? 遇到同样的问题,group id 没有带过去

xiongxiong-op commented 4 years ago

@Autowired RestTemplateRequestInterceptor restTemplateRequestInterceptor;

@Bean @LoadBalanced public RestTemplate restTemplate( HttpMessageConverters fastJsonHttpMessageConverters) { RestTemplate restTemplate = new RestTemplate( fastJsonHttpMessageConverters.getConverters()); restTemplate.setInterceptors(Collections.singletonList(restTemplateRequestInterceptor)); return restTemplate; }