Back to Home
divaxi icon

SQL-QueryDSL-query-mcp-server

Verified Safe

by divaxi

Overview

Serves as a Model Context Protocol (MCP) server for AI clients to query and filter data from a SQL database using QueryDSL.

Installation

Run Command
java -Dspring.ai.mcp.server.stdio=true -jar /path/to/your/app/target/ai-0.0.1-SNAPSHOT.jar

Environment Variables

  • POSTGRES_DB
  • POSTGRES_PASSWORD
  • POSTGRES_USER

Security Notes

The server utilizes QueryDSL, which provides type-safe query building and helps prevent SQL injection by avoiding raw string concatenation in queries. Incoming queries are deserialized into a strictly defined JSON schema, limiting arbitrary input and operations. However, the provided `compose.yaml` for setting up the database includes hardcoded default credentials (e.g., `POSTGRES_PASSWORD=secret`), which are not suitable for production environments and must be changed by the user.

Similar Servers

Stats

Interest Score30
Security Score8
Cost ClassMedium
Avg Tokens500
Stars1
Forks0
Last Update2025-12-12

Tags

SQLQueryDSLSpring BootMCP ServerData Filtering