mirror of
https://gitcode.com/ageerle/ruoyi-ai.git
synced 2026-04-03 06:53:45 +08:00
feat:基于stdio模式 启动mcp服务器
This commit is contained in:
@@ -49,6 +49,8 @@ public class McpInfo extends BaseEntity {
|
||||
*/
|
||||
private String arguments;
|
||||
|
||||
private String description;
|
||||
|
||||
/**
|
||||
* Env
|
||||
*/
|
||||
|
||||
@@ -44,8 +44,8 @@ public class McpInfoBo implements Serializable {
|
||||
* Args
|
||||
*/
|
||||
private String arguments;
|
||||
|
||||
/**
|
||||
private String description;
|
||||
/**
|
||||
* Env
|
||||
*/
|
||||
private String env;
|
||||
|
||||
@@ -14,7 +14,7 @@ import java.io.Serializable;
|
||||
/**
|
||||
* MCP视图对象 mcp_info
|
||||
*
|
||||
* @author ageerle
|
||||
* @author jiyi
|
||||
* @date Sat Aug 09 16:50:58 CST 2025
|
||||
*/
|
||||
@Data
|
||||
@@ -47,7 +47,8 @@ public class McpInfoVo implements Serializable {
|
||||
*/
|
||||
@ExcelProperty(value = "Args")
|
||||
private String arguments;
|
||||
|
||||
@ExcelProperty(value = "Description")
|
||||
private String description;
|
||||
/**
|
||||
* Env
|
||||
*/
|
||||
|
||||
@@ -1,18 +1,33 @@
|
||||
package org.ruoyi.mapper;
|
||||
|
||||
|
||||
import org.apache.ibatis.annotations.*;
|
||||
import org.ruoyi.core.mapper.BaseMapperPlus;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.ruoyi.domain.McpInfo;
|
||||
import org.ruoyi.domain.vo.McpInfoVo;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* MCPMapper接口
|
||||
*
|
||||
* @author ageerle
|
||||
* @author jiuyi
|
||||
* @date Sat Aug 09 16:50:58 CST 2025
|
||||
*/
|
||||
@Mapper
|
||||
public interface McpInfoMapper extends BaseMapperPlus<McpInfo, McpInfoVo> {
|
||||
@Select("SELECT * FROM mcp_info WHERE server_name = #{serverName}")
|
||||
McpInfo selectByServerName(@Param("serverName") String serverName);
|
||||
|
||||
@Select("SELECT * FROM mcp_info WHERE status = 1")
|
||||
List<McpInfo> selectActiveServers();
|
||||
|
||||
@Select("SELECT server_name FROM mcp_info WHERE status = 1")
|
||||
List<String> selectActiveServerNames();
|
||||
|
||||
@Update("UPDATE mcp_info SET status = #{status} WHERE server_name = #{serverName}")
|
||||
int updateActiveStatus(@Param("serverName") String serverName, @Param("status") Boolean status);
|
||||
|
||||
@Delete("DELETE FROM mcp_info WHERE server_name = #{serverName}")
|
||||
int deleteByServerName(@Param("serverName") String serverName);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user