From bd23f81d85a105a2cf7d3d4103010c9ea2b4985c Mon Sep 17 00:00:00 2001 From: alzimmermsft <48699787+alzimmermsft@users.noreply.github.com> Date: Thu, 26 Mar 2026 10:37:51 -0400 Subject: [PATCH 1/2] Fix incorrect SignalR caching --- servers/Azure.Mcp.Server/changelog-entries/1774535859275.yaml | 3 +++ tools/Azure.Mcp.Tools.SignalR/src/Services/SignalRService.cs | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) create mode 100644 servers/Azure.Mcp.Server/changelog-entries/1774535859275.yaml diff --git a/servers/Azure.Mcp.Server/changelog-entries/1774535859275.yaml b/servers/Azure.Mcp.Server/changelog-entries/1774535859275.yaml new file mode 100644 index 0000000000..8ad6904bbc --- /dev/null +++ b/servers/Azure.Mcp.Server/changelog-entries/1774535859275.yaml @@ -0,0 +1,3 @@ +changes: + - section: "Bugs Fixed" + description: "Fix incorrect SignalR caching" \ No newline at end of file diff --git a/tools/Azure.Mcp.Tools.SignalR/src/Services/SignalRService.cs b/tools/Azure.Mcp.Tools.SignalR/src/Services/SignalRService.cs index 3f0fd6f589..e0cd070cba 100644 --- a/tools/Azure.Mcp.Tools.SignalR/src/Services/SignalRService.cs +++ b/tools/Azure.Mcp.Tools.SignalR/src/Services/SignalRService.cs @@ -77,7 +77,7 @@ public async Task> GetRuntimeAsync( runtimes.Add(ConvertToRuntimeModel(runtime)); } - await _cacheService.SetAsync(CacheGroup, cacheKey, signalRName, s_cacheDuration, cancellationToken); + await _cacheService.SetAsync(CacheGroup, cacheKey, runtimes, s_cacheDuration, cancellationToken); } } else @@ -106,7 +106,7 @@ public async Task> GetRuntimeAsync( } runtimes.Add(ConvertToRuntimeModel(signalRResource.Value)); - await _cacheService.SetAsync(CacheGroup, cacheKey, signalRName, s_cacheDuration, cancellationToken); + await _cacheService.SetAsync(CacheGroup, cacheKey, runtimes, s_cacheDuration, cancellationToken); } return runtimes; From 0333469671f222bc3414bc897ed53442f9026883 Mon Sep 17 00:00:00 2001 From: alzimmermsft <48699787+alzimmermsft@users.noreply.github.com> Date: Thu, 26 Mar 2026 11:16:52 -0400 Subject: [PATCH 2/2] Move caching spot --- tools/Azure.Mcp.Tools.SignalR/src/Services/SignalRService.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/Azure.Mcp.Tools.SignalR/src/Services/SignalRService.cs b/tools/Azure.Mcp.Tools.SignalR/src/Services/SignalRService.cs index e0cd070cba..d974c9d11f 100644 --- a/tools/Azure.Mcp.Tools.SignalR/src/Services/SignalRService.cs +++ b/tools/Azure.Mcp.Tools.SignalR/src/Services/SignalRService.cs @@ -76,9 +76,9 @@ public async Task> GetRuntimeAsync( { runtimes.Add(ConvertToRuntimeModel(runtime)); } - - await _cacheService.SetAsync(CacheGroup, cacheKey, runtimes, s_cacheDuration, cancellationToken); } + + await _cacheService.SetAsync(CacheGroup, cacheKey, runtimes, s_cacheDuration, cancellationToken); } else {