package com.njcn.prepare.harmonic.api.line;

import com.njcn.common.pojo.constant.ServerInfo;
import com.njcn.common.pojo.response.HttpResult;
import com.njcn.prepare.harmonic.api.line.fallback.DistortionRateFeignClientFallbackFactory;
import com.njcn.prepare.harmonic.pojo.param.LineParam;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * 稳态综合评估
 * @author xiaoyao
 * @version 1.0.0
 * @createTime 2022/11/7 15:11
 */

@FeignClient(
        value = ServerInfo.PREPARE_BOOT,
        path = "/general",
        fallbackFactory = DistortionRateFeignClientFallbackFactory.class
)
public interface HarmonicGeneralFeignClient {

    @PostMapping("/generalData")
    HttpResult<String> generalData(@RequestBody @Validated LineParam lineParam);

    @PostMapping("/generalDataToMysql")
    HttpResult<String> generalDataToMysql(@RequestBody @Validated LineParam lineParam);
}
