package com.css.simulation.resource.server.infra.feign.service;

import api.common.pojo.common.ResponseBodyVO;
import api.common.pojo.po.system.SceneEvaluationRuleScriptPO;
import api.common.pojo.po.system.SceneImportPO;
import com.css.simulation.resource.server.infra.feign.config.FeignConfiguration;
import com.css.simulation.resource.server.infra.feign.fallback.SceneServiceFallback;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.scheduling.annotation.Async;
import org.springframework.web.bind.annotation.PostMapping;



@FeignClient(
        //name = "scene",
        //url = "http://127.0.0.1:7005",
        contextId = "scene",
        value = "simulation-resource-scene",
        path = "/simulation/resource/scene",
        fallback = SceneServiceFallback.class,
        configuration = FeignConfiguration.class)
public interface SceneService {

    @Async
    @PostMapping("/sceneImport/startImport")
    ResponseBodyVO startImport(SceneImportPO po);

    @Async
    @PostMapping("/sceneImport/startImportEvaluationScript")
    ResponseBodyVO startImportEvaluationScript(SceneEvaluationRuleScriptPO po);

}
