Commit 6e183dae by 阳浪

配置信息

parent 2d3f0597
......@@ -83,4 +83,9 @@
</plugin>
</plugins>
</build>
<properties>
<!-- 跳过测试 -->
<skipTests>true</skipTests>
</properties>
</project>
......@@ -2,6 +2,7 @@ package com.yizhi.library.application;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.amqp.RabbitAutoConfiguration;
import org.springframework.cache.annotation.EnableCaching;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.cloud.openfeign.EnableFeignClients;
......@@ -14,7 +15,7 @@ import org.springframework.context.annotation.ComponentScan;
* @date 2019/7/1
**/
@SpringBootApplication
@SpringBootApplication(exclude = {RabbitAutoConfiguration.class})
@EnableDiscoveryClient
@EnableCaching
@EnableFeignClients(basePackages = {"com.yizhi"})
......
......@@ -24,7 +24,6 @@ import com.yizhi.system.application.system.remote.AccountClient;
import com.yizhi.system.application.vo.AccountVO;
import com.yizhi.util.application.event.TrainingProjectEvent;
import org.apache.commons.collections.CollectionUtils;
import org.springframework.amqp.core.AmqpTemplate;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
......@@ -56,9 +55,9 @@ public class StudentCaseController implements StudentCaseClient {
@Autowired
private TaskExecutor taskExecutor;
/*
@Autowired
private AmqpTemplate amqpTemplate;
private AmqpTemplate amqpTemplate;*/
@Autowired
private StudentCaseServiceImpl studentCaseServiceImpl;
......@@ -142,11 +141,11 @@ public class StudentCaseController implements StudentCaseClient {
public void handle() {
try {
amqpTemplate.convertAndSend(Constant.TRAINING_PROJECT_EVENT_QUEUE,
/*amqpTemplate.convertAndSend(Constant.TRAINING_PROJECT_EVENT_QUEUE,
new EventWrapper<TrainingProjectEvent>(caseLibraryId,
TrainingProjectEvent.getInstance(caseLibraryId, Constant.CASELIBRARY_TRANINNING_TYPE, accountId, now, siteId, false
))
);
);*/
} catch (Exception e) {
e.printStackTrace();
}
......
......@@ -46,7 +46,6 @@ import org.apache.commons.lang3.StringUtils;
import org.apache.commons.lang3.math.NumberUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.amqp.core.AmqpTemplate;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
......@@ -108,9 +107,9 @@ public class StudentCaseServiceImpl extends ServiceImpl<StudentCaseMapper, Stude
@Autowired
private PointRedisFeignClients pointRedisFeignClients;
/*
@Autowired
private AmqpTemplate amqpTemplate;
private AmqpTemplate amqpTemplate;*/
@Autowired
private ReportClient reportClient;
......@@ -391,11 +390,11 @@ public class StudentCaseServiceImpl extends ServiceImpl<StudentCaseMapper, Stude
public void handle() {
try {
amqpTemplate.convertAndSend(Constant.TRAINING_PROJECT_EVENT_QUEUE,
/* amqpTemplate.convertAndSend(Constant.TRAINING_PROJECT_EVENT_QUEUE,
new EventWrapper<TrainingProjectEvent>(caseLibraryId,
TrainingProjectEvent.getInstance(caseLibraryId, Constant.CASELIBRARY_TRANINNING_TYPE, accountId, now, siteId, false
))
);
);*/
} catch (Exception e) {
e.printStackTrace();
}
......@@ -789,11 +788,11 @@ public class StudentCaseServiceImpl extends ServiceImpl<StudentCaseMapper, Stude
public void handle() {
try {
amqpTemplate.convertAndSend(Constant.TRAINING_PROJECT_EVENT_QUEUE,
/* amqpTemplate.convertAndSend(Constant.TRAINING_PROJECT_EVENT_QUEUE,
new EventWrapper<TrainingProjectEvent>(studentCaseId,
TrainingProjectEvent.getInstance(studentCaseId, Constant.STUDENTCASE_TRANINNING_TYPE, res.getAccountId(), now, res.getSiteId(), true
))
);
);*/
} catch (Exception e) {
e.printStackTrace();
}
......@@ -932,7 +931,7 @@ public class StudentCaseServiceImpl extends ServiceImpl<StudentCaseMapper, Stude
//发送积分获取消息
if (null != sitePointId) {
amqpTemplate.convertAndSend(MQqueuesEnum.CASELIBRARY.getKey(), sitePointId);
// amqpTemplate.convertAndSend(MQqueuesEnum.CASELIBRARY.getKey(), sitePointId);
}
}
});
......@@ -948,11 +947,11 @@ public class StudentCaseServiceImpl extends ServiceImpl<StudentCaseMapper, Stude
public void handle() {
try {
amqpTemplate.convertAndSend(Constant.TRAINING_PROJECT_EVENT_QUEUE,
/* amqpTemplate.convertAndSend(Constant.TRAINING_PROJECT_EVENT_QUEUE,
new EventWrapper<TrainingProjectEvent>(finalCaseLibraryId1,
TrainingProjectEvent.getInstance(finalCaseLibraryId1, Constant.CASELIBRARY_TRANINNING_TYPE, finalAccountId1, now, siteId, true
))
);
);*/
} catch (Exception e) {
e.printStackTrace();
}
......
server.port=34666
spring.application.name=caselibrary
ACTIVE=${spring.profiles.active}
spring.profiles.active=dev
spring.profiles.active=prod
# nacos
spring.cloud.nacos.config.shared-dataids=common-${spring.profiles.active}.properties
spring.cloud.nacos.config.namespace=${spring.profiles.active}
spring.cloud.nacos.config.prefix=${spring.application.name}
spring.cloud.nacos.config.file-extension=properties
spring.cloud.nacos.config.server-addr=192.168.1.22:3333,192.168.1.22:4444,192.168.1.22:5555
\ No newline at end of file
spring.cloud.nacos.config.server-addr=10.23.1.183:8848
\ No newline at end of file
......@@ -24,8 +24,8 @@
<repositories>
<repository>
<id>learning-data-group</id>
<url>http://192.168.0.15:8081/repository/learning-data-group/</url>
<id>hqzhdj-data-group</id>
<url>http://192.168.0.15:8081/repository/hqzhdj-data-group/</url>
<releases>
<enabled>true</enabled>
</releases>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment