♻️Refactor: 简化微服务

This commit is contained in:
2025-10-29 16:08:19 +08:00
parent c0b89fcd95
commit 060466b7b7
26 changed files with 20 additions and 195 deletions
-5
View File
@@ -17,11 +17,6 @@
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-openfeign</artifactId>
</dependency>
<dependency>
<groupId>com.larksuite.oapi</groupId>
<artifactId>oapi-sdk</artifactId>
@@ -1,14 +1,11 @@
package cn.hezhaohui.lark;
import cn.hezhaohui.lark.client.WeatherClient;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.openfeign.EnableFeignClients;
import static cn.hezhaohui.lark.handler.EventListener.larkClientStart;
@SpringBootApplication
@EnableFeignClients
public class LarkApplication {
public static void main(String[] args) {
@@ -1,8 +1,7 @@
package cn.hezhaohui.lark.client;
import cn.hezhaohui.weather.entity.Weather;
import cn.hezhaohui.entity.Weather;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
@FeignClient(name = "service-weather")
@@ -1,6 +1,6 @@
package cn.hezhaohui.lark.handler;
import cn.hezhaohui.weather.common.AppConstant;
import cn.hezhaohui.common.AppConstant;
import com.lark.oapi.core.request.EventReq;
import com.lark.oapi.core.utils.Jsons;
import com.lark.oapi.event.CustomEventHandler;
@@ -1,7 +1,7 @@
package cn.hezhaohui.lark.util;
import cn.hezhaohui.weather.common.AppConstant;
import cn.hezhaohui.weather.common.CardEnum;
import cn.hezhaohui.common.AppConstant;
import cn.hezhaohui.common.CardEnum;
import cn.hutool.core.util.IdUtil;
import cn.hutool.json.JSONUtil;
import com.google.gson.JsonParser;
@@ -1,8 +1,8 @@
package cn.hezhaohui.lark.util;
import cn.hezhaohui.lark.client.WeatherClient;
import cn.hezhaohui.weather.common.CardEnum;
import cn.hezhaohui.weather.entity.Weather;
import cn.hezhaohui.common.CardEnum;
import cn.hezhaohui.entity.Weather;
import jakarta.annotation.Resource;
import org.junit.jupiter.api.Test;
import org.springframework.boot.test.context.SpringBootTest;