AWS Glue数据目录模型上下文协议服务器

一个用于AWS Glue数据目录的模型上下文协议(MCP)服务器,支持通过MCP调用查询和管理数据目录。

  • by atcol
  • Rust
  • 混合部署
  • 1 星标
  • 更新于
在 GitHub 查看 atcol/glue-mcp

使用说明

胶水mcp

AWS Glue数据目录的模型上下文协议(MCP)服务器

用法

构建二进制文件后(见下文),请确保设置了AWS凭据。

然后简单地启动服务器:

./glue-mcp
2025-04-29T21:25:37.623408Z  INFO glue_mcp: Metrics & logging initialised
2025-04-29T21:25:37.623453Z  INFO glue_mcp::util: Starting server on 127.0.0.1:8000

服务器已准备好在端口8000上进行MCP调用。

发展

尼克斯

跑 nix develop那么 cargo build.

演示

我们将演示如何使用Ollama。

1.安装和配置 mcphost

go install github.com/mark3labs/mcphost@latest

使用此MCP服务器配置mcphost:

{
  "mcpServers": {
    "aws_glue": {
      "url": "http://localhost:8000/sse",
      "transport": "sse"
    }
  }
}

2.配置Olama

获取模型:

ollama pull llama3.1:latest

4.跑步 glue-mcp

cargo run

5.运行mcphost查询

~/go/bin/mcphost --config ./mcp.json --model ollama:llama3.1
2025/04/27 11:46:02 INFO Initializing server... name=aws_glue
2025/04/27 11:46:02 INFO Server connected name=aws_glue             
2025/04/27 11:46:02 INFO Tools loaded server=aws_glue count=3                                                                           
                                                                                                                                        
  You: list databases             
2025/04/27 11:47:11 INFO 🔧 Using tool name=aws_glue__list_databases
                                                                    
  Assistant:                                                                                                          
                                                                                                                                        
                                                                    
  The available databases are 'reference_data' and 'unstructured'.                                                                      
                                                                                                                                        


  You: list tables per database                                     
2025/04/27 11:47:40 INFO 🔧 Using tool name=aws_glue__get_database_metadata
2025/04/27 11:47:45 INFO 🔧 Using tool name=aws_glue__get_database_metadata

  Assistant:                                                                                                          


  The 'unstructured' database is currently empty of tables. The 'reference_data' database also does not contain any   
  tables.