Commit e1c612a2 by tyfanchz

调整代码

1 parent e2462c68
......@@ -8,13 +8,12 @@ import org.springframework.boot.web.servlet.ServletComponentScan;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.annotation.ComponentScan;
/**
* @Title: ServiceApplication.java
* @Description:
* @author deployer name
* @version V1.0
* @author deployer name
* @version V1.0
* @Company: Didihu.com.cn
* @Copyright Copyright (c) 2015
*/
......@@ -24,7 +23,6 @@ import org.springframework.context.annotation.ComponentScan;
@ServletComponentScan
@EnableFeignClients
@EnableDubbo
@ComponentScan("com.glsx.admin")
public class SmartAdminApplication extends SpringBootServletInitializer {
/**
......
......@@ -6,7 +6,7 @@ import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;
@FeignClient(name = "${feigin.server.name}",url = "${feigin.server.url}", fallback = IndexHystrix.class)
@FeignClient(name = "${feign.server.name}",url = "${feign.server.url}", fallback = IndexHystrix.class)
public interface IndexFeignClient {
@ResponseBody
......
package com.glsx.admin.remote;
import com.github.pagehelper.PageInfo;
import com.glsx.admin.pojo.request.SmartProductReq;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;
/**
* <p>Description:
* <p>Project: chejia-smart
*
* @author wbh
* @date 2021-03-16
*/
@FeignClient(name = "${feign.server.name}",url = "${feign.server.url}")
public interface ProductFeignClient {
@RequestMapping(value = "/product/getList", method = {RequestMethod.GET})
@ResponseBody
PageInfo<SmartProductReq> getList(SmartProductReq req);
}
......@@ -16,9 +16,9 @@ logging.level.org.springframework.boot.autoconfigure=off
logging.level.com.glsx.admin=DEBUG
logging.path=/data/java_log/jetty/smartService/chejia-smart-admin
feigin.server.name=chejia-smart-service
feigin.server.url=http://localhost:8209/smartService
feign.server.name=chejia-smart-service
feign.server.url=http://localhost:8209/smartService
dubbo.registry.address=zookeeper://192.168.1.36:2181
dubbo.registry.address=zookeeper://192.168.1.36:2181?init.timeout=60000
dubbo.registry.timeout=10000
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!