|
@@ -61,6 +61,12 @@ public class GameUserRoleServiceImpl extends ServiceImpl<GameUserRoleMapper, Gam
|
|
|
@Value("${spring.kafka.game-sdk.gameRoleActiveTopic}")
|
|
|
private String gameRoleActiveTopic;
|
|
|
|
|
|
+ /**
|
|
|
+ * 服务器域名
|
|
|
+ */
|
|
|
+ @Value("${server.domain}")
|
|
|
+ private String serverUrl;
|
|
|
+
|
|
|
@Autowired
|
|
|
@Qualifier("gameSdkKafkaProducer")
|
|
|
private KafkaProducer<String, String> kafkaProducer;
|
|
@@ -246,6 +252,10 @@ public class GameUserRoleServiceImpl extends ServiceImpl<GameUserRoleMapper, Gam
|
|
|
userTokenService.userTokenUpdateCheck(userData);
|
|
|
} catch (Exception ignored) {
|
|
|
}
|
|
|
+ //测试环境不使用kafka
|
|
|
+ if (this.serverUrl.contains("test")) {
|
|
|
+ return Boolean.FALSE;
|
|
|
+ }
|
|
|
//活跃提交
|
|
|
Map<String, Object> activeParamMap = new HashMap<>(6);
|
|
|
activeParamMap.put("userId", userData.getUserId());
|