Skip to content

Conversation

@nquinquenel
Copy link
Member

No description provided.

@hashicorp-vault-sonar-prod
Copy link

hashicorp-vault-sonar-prod bot commented Dec 5, 2025

MCP-186
MCP-196
MCP-216

@nquinquenel nquinquenel marked this pull request as ready for review December 5, 2025 16:07
Copy link
Contributor

@damien-urruty-sonarsource damien-urruty-sonarsource left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In theory I think you could configure Logback to append to stderr, so it's done automatically when doing e.g. LOG.info(message);. But it's not too much code, so even like this it's fine

@sonarqubecloud
Copy link

sonarqubecloud bot commented Dec 5, 2025

SonarQube reviewer guide

Important

We are currently testing different models for AI Summary.
Please give us your feedback by filling this form.

Model A:

Summary: Remove container name from Docker commands and add OCI runtime compatibility note.

Review Focus: Documentation cleanup removing hardcoded --name sonarqube-mcp-server parameter from all Docker commands; enhanced logging to output to STDERR for MCP protocol compliance.

Start review at: src/main/java/org/sonarsource/sonarqube/mcp/log/McpLogger.java. This code change implements dual logging (STDERR + file) to comply with MCP protocol requirements where STDOUT is reserved for JSON-RPC.

Model B:

Summary: Update documentation to remove hardcoded container names and clarify OCI-compatible runtime support, plus enhance logging to output diagnostics to STDERR for MCP clients.

Review Focus:

  • The logging changes in McpLogger.java introduce STDERR output alongside existing SLF4J logging. Verify this dual-logging approach doesn't create excessive noise or duplicate messages in MCP client logs.
  • Ensure the printStackTrace() call on exceptions won't cause performance issues if errors occur frequently.

Start review at: src/main/java/org/sonarsource/sonarqube/mcp/log/McpLogger.java. This is the only code change and contains the functional logic modifications; all other changes are documentation updates that don't require code review scrutiny.

Quality Gate Passed Quality Gate passed

Issues
0 New issues
2 Accepted issues
0 Dependency risks

Measures
0 Security Hotspots
100.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarQube Cloud

@nquinquenel nquinquenel merged commit ef8ae88 into master Dec 5, 2025
3 checks passed
@nquinquenel nquinquenel deleted the task/nq/hardening branch December 5, 2025 18:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants