Skip to content

Commit 1be8083

Browse files
committed
Remove stale telemetry
As far as I know, we've never used this, and the numbers don't indicate that there is a problem
1 parent 51dd711 commit 1be8083

File tree

1 file changed

+0
-17
lines changed

1 file changed

+0
-17
lines changed

src/Razor/src/Microsoft.CodeAnalysis.Remote.Razor/OOPTagHelperResolver.cs

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -186,16 +186,10 @@ protected virtual async ValueTask<ImmutableArray<TagHelperDescriptor>> ResolveTa
186186
// Protected virtual for testing
187187
protected virtual ImmutableArray<Checksum> ProduceChecksumsFromDelta(ProjectId projectId, int lastResultId, TagHelperDeltaResult deltaResult)
188188
{
189-
using var _ = StopwatchPool.GetPooledObject(out var stopWatch);
190-
stopWatch.Restart();
191-
192-
var fromCache = true;
193-
194189
if (!_resultCache.TryGet(projectId, lastResultId, out var checksums))
195190
{
196191
// We most likely haven't made a request to the server yet so there's no delta to apply
197192
checksums = ImmutableArray<Checksum>.Empty;
198-
fromCache = false;
199193

200194
if (deltaResult.IsDelta)
201195
{
@@ -208,24 +202,13 @@ protected virtual ImmutableArray<Checksum> ProduceChecksumsFromDelta(ProjectId p
208202
{
209203
// Not a delta based response, we should treat it as a "refresh"
210204
checksums = ImmutableArray<Checksum>.Empty;
211-
fromCache = false;
212205
}
213206

214207
if (deltaResult.ResultId != lastResultId)
215208
{
216209
// New results, lets build a coherent TagHelper collection and then cache it
217210
checksums = deltaResult.Apply(checksums);
218211
_resultCache.Set(projectId, deltaResult.ResultId, checksums);
219-
fromCache = false;
220-
}
221-
222-
stopWatch.Stop();
223-
if (fromCache)
224-
{
225-
_telemetryReporter.ReportEvent(
226-
"taghelpers.fromcache",
227-
Severity.Normal,
228-
new Property("taghelper.cachedresult.ellapsedms", stopWatch.ElapsedMilliseconds));
229212
}
230213

231214
return checksums;

0 commit comments

Comments
 (0)