升级 Dubbo 到 2.7.1 。目前 Dubbo 引用服务存在 Bug ,所以需要使用 @Autowire 解决下。
This commit is contained in:
@@ -15,12 +15,10 @@
|
||||
|
||||
<artifactId>user-service-impl</artifactId>
|
||||
<dependencies>
|
||||
|
||||
<dependency>
|
||||
<groupId>cn.iocoder.mall</groupId>
|
||||
<artifactId>user-service-api</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -38,9 +36,21 @@
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.alibaba</groupId>
|
||||
<groupId>org.apache.dubbo</groupId>
|
||||
<artifactId>dubbo</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.curator</groupId>
|
||||
<artifactId>curator-framework</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.curator</groupId>
|
||||
<artifactId>curator-recipes</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.dubbo</groupId>
|
||||
<artifactId>dubbo-spring-boot-starter</artifactId>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@ import java.util.Date;
|
||||
* MobileCodeService ,实现用户登陆时需要的验证码
|
||||
*/
|
||||
@Service
|
||||
@com.alibaba.dubbo.config.annotation.Service
|
||||
@org.apache.dubbo.config.annotation.Service
|
||||
public class MobileCodeServiceImpl implements MobileCodeService {
|
||||
|
||||
/**
|
||||
@@ -107,4 +107,4 @@ public class MobileCodeServiceImpl implements MobileCodeService {
|
||||
return CommonResult.success(null);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -27,7 +27,7 @@ import java.util.UUID;
|
||||
* OAuth2Service ,实现用户授权相关的逻辑
|
||||
*/
|
||||
@Service
|
||||
@com.alibaba.dubbo.config.annotation.Service
|
||||
@org.apache.dubbo.config.annotation.Service
|
||||
public class OAuth2ServiceImpl implements OAuth2Service {
|
||||
|
||||
/**
|
||||
|
||||
@@ -13,7 +13,7 @@ import org.springframework.stereotype.Service;
|
||||
import java.util.Date;
|
||||
|
||||
@Service
|
||||
@com.alibaba.dubbo.config.annotation.Service(validation = "true")
|
||||
@org.apache.dubbo.config.annotation.Service(validation = "true")
|
||||
public class UserAccessLogServiceImpl implements UserAccessLogService {
|
||||
|
||||
/**
|
||||
@@ -53,4 +53,4 @@ public class UserAccessLogServiceImpl implements UserAccessLogService {
|
||||
return CommonResult.success(true);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -26,7 +26,7 @@ import java.util.List;
|
||||
* @time 2019-04-06 13:26
|
||||
*/
|
||||
@Service
|
||||
@com.alibaba.dubbo.config.annotation.Service(validation = "true")
|
||||
@org.apache.dubbo.config.annotation.Service(validation = "true")
|
||||
public class UserAddressServiceImpl implements UserAddressService {
|
||||
|
||||
@Autowired
|
||||
|
||||
@@ -5,10 +5,6 @@ import cn.iocoder.common.framework.constant.SysErrorCodeEnum;
|
||||
import cn.iocoder.common.framework.util.ServiceExceptionUtil;
|
||||
import cn.iocoder.common.framework.util.ValidationUtil;
|
||||
import cn.iocoder.common.framework.vo.CommonResult;
|
||||
import cn.iocoder.mall.user.biz.dao.UserMapper;
|
||||
import cn.iocoder.mall.user.biz.dao.UserRegisterMapper;
|
||||
import cn.iocoder.mall.user.biz.dataobject.UserDO;
|
||||
import cn.iocoder.mall.user.biz.dataobject.UserRegisterDO;
|
||||
import cn.iocoder.mall.user.api.UserService;
|
||||
import cn.iocoder.mall.user.api.bo.UserBO;
|
||||
import cn.iocoder.mall.user.api.bo.UserPageBO;
|
||||
@@ -17,7 +13,12 @@ import cn.iocoder.mall.user.api.constant.UserErrorCodeEnum;
|
||||
import cn.iocoder.mall.user.api.dto.UserPageDTO;
|
||||
import cn.iocoder.mall.user.api.dto.UserUpdateDTO;
|
||||
import cn.iocoder.mall.user.biz.convert.UserConvert;
|
||||
import cn.iocoder.mall.user.biz.dao.UserMapper;
|
||||
import cn.iocoder.mall.user.biz.dao.UserRegisterMapper;
|
||||
import cn.iocoder.mall.user.biz.dataobject.UserDO;
|
||||
import cn.iocoder.mall.user.biz.dataobject.UserRegisterDO;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.util.Date;
|
||||
@@ -25,8 +26,8 @@ import java.util.Date;
|
||||
/**
|
||||
* UserService ,实现和用户信息相关的逻辑
|
||||
*/
|
||||
@org.springframework.stereotype.Service
|
||||
@com.alibaba.dubbo.config.annotation.Service
|
||||
@Service
|
||||
@org.apache.dubbo.config.annotation.Service(validation = "true")
|
||||
public class UserServiceImpl implements UserService {
|
||||
|
||||
@Autowired
|
||||
@@ -148,4 +149,4 @@ public class UserServiceImpl implements UserService {
|
||||
|| UserConstants.STATUS_DISABLE.equals(status);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user