package com.ghb.base.modules.test.feign.client;

import com.ghb.base.common.api.vo.Result;

import com.ghb.base.common.constant.ServiceNameConstants;
import org.jeecg.config.FeignConfig;
import com.ghb.base.modules.test.constant.CloudConstant;
import com.ghb.base.modules.test.feign.factory.GhbTestClientFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * 常规feign接口定义
 * @author: zyf
 * @date: 2022/04/21
 */
@FeignClient(value = ServiceNameConstants.SERVICE_DEMO, configuration = FeignConfig.class,fallbackFactory = GhbTestClientFactory.class)
@Component
public interface GhbTestClient {

    /**
     * feign测试方法
     * @param name
     * @return
     */
    @GetMapping(value = "/test/getMessage")
    String getMessage(@RequestParam(value = "name",required = false) String name);
}
