Chunk #555

Aus: Infrastructure (Index: 4)

91 Tokens
Synced Status
« Vorheriger (#3)

Taxonomie

Kategorie Infrastructure
Pfad Infrastructure > MCP-DB Infrastructure > Database Connection
Heading-Pfad Infrastructure > MCP-DB Infrastructure > Nutzung

Entities

Name Typ
DatabaseConnection SERVICE
cursor TECHNOLOGY
ProtokollLogger SERVICE
LogEntry CONCEPT
mcp_log CONFIG

Keywords

database connection log cursor protocol

Inhalt

# DatabaseConnection
with DatabaseConnection.get_connection("ki_protokoll") as conn:
    cursor = conn.cursor(dictionary=True)
    cursor.execute("SELECT * FROM mcp_log LIMIT 10")
    rows = cursor.fetchall()
    cursor.close()

# ProtokollLogger
logger = ProtokollLogger()
logger.log(LogEntry(
    request="SELECT * FROM mcp_log",
    status="success",
    duration_ms=45
))

Clean Content

```
`# DatabaseConnection
with DatabaseConnection.get_connection("ki_protokoll") as conn:
 cursor = conn.cursor(dictionary=True)
 cursor.execute("SELECT * FROM mcp_log LIMIT 10")
 rows = cursor.fetchall()
 cursor.close()

# ProtokollLogger
logger = ProtokollLogger()
logger.log(LogEntry(
 request="SELECT * FROM mcp_log",
 status="success",
 duration_ms=45
))`
```

Metadaten

Analysiert am20.12.2025 12:44:14
Analyse-Modellgemma3:4b-it-qat
Embedding-Modellmxbai-embed-large
Qdrant-ID3857faa4-07f0-4eb5-98ba-db809f416bf8
Erstellt20.12.2025 12:34:42
Aktualisiert20.12.2025 12:53:39