Skip to content

Commit 759a5b8

Browse files
committed
Improve ToolCallback naming consistency in MCP client configuration
- Keep ToolCallback as internal class name in McpClientCommonProperties - Maintain toolCallback field name and getter/setter methods - Use .toolcallback configuration property path - Update all related test files to use consistent naming - All tests pass and functionality remains intact This change ensures naming consistency with Spring AI project conventions where Properties internal classes use descriptive names rather than Config suffixes. Signed-off-by: huidong.yin <[email protected]>
1 parent 5df83cb commit 759a5b8

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

auto-configurations/mcp/spring-ai-autoconfigure-mcp-client-common/src/main/java/org/springframework/ai/mcp/client/common/autoconfigure/properties/McpClientCommonProperties.java

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ public enum ClientType {
103103
* <p>
104104
* This configuration is used to enable or disable tool callbacks in the MCP client.
105105
*/
106-
private Toolcallback toolcallback = new Toolcallback();
106+
private ToolCallback toolCallback = new ToolCallback();
107107

108108
public boolean isEnabled() {
109109
return this.enabled;
@@ -161,22 +161,22 @@ public void setRootChangeNotification(boolean rootChangeNotification) {
161161
this.rootChangeNotification = rootChangeNotification;
162162
}
163163

164-
public Toolcallback getToolcallback() {
165-
return this.toolcallback;
164+
public ToolCallback getToolCallback() {
165+
return this.toolCallback;
166166
}
167167

168-
public void setToolcallback(Toolcallback toolcallback) {
169-
this.toolcallback = toolcallback;
168+
public void setToolCallback(ToolCallback toolCallback) {
169+
this.toolCallback = toolCallback;
170170
}
171171

172172
/**
173173
* Represents a callback configuration for tools.
174174
* <p>
175-
* This record is used to encapsulate the configuration for enabling or disabling tool
175+
* This class is used to encapsulate the configuration for enabling or disabling tool
176176
* callbacks in the MCP client.
177177
*
178178
*/
179-
public static class Toolcallback {
179+
public static class ToolCallback {
180180

181181
/**
182182
* A boolean flag indicating whether the tool callback is enabled. If true, the

auto-configurations/mcp/spring-ai-autoconfigure-mcp-client-common/src/main/java/org/springframework/ai/mcp/client/common/autoconfigure/properties/McpStreamableHttpClientProperties.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ public Map<String, ConnectionParameters> getConnections() {
6363
}
6464

6565
/**
66-
* Parameters for configuring an Streamable Http connection to an MCP server.
66+
* Parameters for configuring a Streamable Http connection to an MCP server.
6767
*
6868
* @param url the URL endpoint for Streamable Http communication with the MCP server
6969
* @param endpoint the endpoint for the MCP server

0 commit comments

Comments
 (0)