From 075edfaf5521ac18fd30bac08567fc0558c00b41 Mon Sep 17 00:00:00 2001 From: Nicholas Blumhardt Date: Thu, 12 Jan 2023 15:37:37 +1000 Subject: [PATCH] Update for Seq 2023.1 - Update dependencies - Remove obsolete direct app installation methods - Remove obsolete cache metrics/update query counter metrics to match 2023.1 semantics - Remove obsolete query execution stats --- .../Data/QueryExecutionStatisticsPart.cs | 18 +---------- .../Model/Diagnostics/ServerMetricsEntity.cs | 32 +------------------ src/Seq.Api/Model/Shared/StatisticsPart.cs | 11 ------- .../Model/Users/SearchHistoryItemPart.cs | 2 +- .../ResourceGroups/AppsResourceGroup.cs | 22 ------------- src/Seq.Api/Seq.Api.csproj | 12 ++++--- 6 files changed, 10 insertions(+), 87 deletions(-) diff --git a/src/Seq.Api/Model/Data/QueryExecutionStatisticsPart.cs b/src/Seq.Api/Model/Data/QueryExecutionStatisticsPart.cs index ac3f6d7..20b9f04 100644 --- a/src/Seq.Api/Model/Data/QueryExecutionStatisticsPart.cs +++ b/src/Seq.Api/Model/Data/QueryExecutionStatisticsPart.cs @@ -19,25 +19,9 @@ namespace Seq.Api.Model.Data /// public class QueryExecutionStatisticsPart { - /// - /// The number of events inspected in the course of computing the query result. This will - /// not include events that could be skipped based on index information or text pre-filtering. - /// - public ulong ScannedEventCount { get; set; } - - /// - /// The number of events that contributed to the query result. - /// - public ulong MatchingEventCount { get; set; } - - /// - /// Whether the query needed to search disk-backed storage. - /// - public bool UncachedSegmentsScanned { get; set; } - /// /// The server-side elapsed time taken to compute the query result. /// public double ElapsedMilliseconds { get; set; } } -} \ No newline at end of file +} diff --git a/src/Seq.Api/Model/Diagnostics/ServerMetricsEntity.cs b/src/Seq.Api/Model/Diagnostics/ServerMetricsEntity.cs index 09928ca..94a4d5f 100644 --- a/src/Seq.Api/Model/Diagnostics/ServerMetricsEntity.cs +++ b/src/Seq.Api/Model/Diagnostics/ServerMetricsEntity.cs @@ -28,26 +28,6 @@ public class ServerMetricsEntity : Entity public ServerMetricsEntity() { } - - /// - /// The start time in UTC of the events in the memory cache. - /// - public DateTime? EventStoreCacheStart { get; set; } - - /// - /// The end time in UTC of the events in the memory cache. - /// - public DateTime? EventStoreCacheEnd { get; set; } - - /// - /// The number of days of events able to fit in the memory cache. - /// - public double EventStoreDaysCached { get; set; } - - /// - /// The number of events able to fit in the memory cache. - /// - public int EventStoreEventsCached { get; set; } /// /// Bytes of free space remaining on the disk used for event storage. @@ -100,18 +80,8 @@ public ServerMetricsEntity() public double SystemMemoryUtilization { get; set; } /// - /// The number of SQL-style queries executed in the past minute. + /// The number of queries and searches executed in the past minute. /// public int QueriesPerMinute { get; set; } - - /// - /// The number of time slices from SQL-style queries that could be read from cache in the past minute. - /// - public int QueryCacheTimeSliceHitsPerMinute { get; set; } - - /// - /// The number of cached SQL query time slices invalidated in the past minute. - /// - public int QueryCacheInvalidationsPerMinute { get; set; } } } diff --git a/src/Seq.Api/Model/Shared/StatisticsPart.cs b/src/Seq.Api/Model/Shared/StatisticsPart.cs index a560132..8dc6c7b 100644 --- a/src/Seq.Api/Model/Shared/StatisticsPart.cs +++ b/src/Seq.Api/Model/Shared/StatisticsPart.cs @@ -26,12 +26,6 @@ public class StatisticsPart /// public TimeSpan Elapsed { get; set; } - /// - /// The number of events that were scanned in the search (and were not - /// able to be excluded based on index information or pre-filtering). - /// - public ulong ScannedEventCount { get; set; } - /// /// The id of the last event inspected in the search. /// @@ -46,10 +40,5 @@ public class StatisticsPart /// Status of the result set. /// public ResultSetStatus Status { get; set; } - - /// - /// Whether it was necessary to read from disk in processing this request. - /// - public bool UncachedSegmentsScanned { get; set; } } } diff --git a/src/Seq.Api/Model/Users/SearchHistoryItemPart.cs b/src/Seq.Api/Model/Users/SearchHistoryItemPart.cs index 6465910..ae8199e 100644 --- a/src/Seq.Api/Model/Users/SearchHistoryItemPart.cs +++ b/src/Seq.Api/Model/Users/SearchHistoryItemPart.cs @@ -31,4 +31,4 @@ public class SearchHistoryItemPart /// public SearchHistoryItemAction Action { get; set; } } -} +} \ No newline at end of file diff --git a/src/Seq.Api/ResourceGroups/AppsResourceGroup.cs b/src/Seq.Api/ResourceGroups/AppsResourceGroup.cs index 727c555..6d18374 100644 --- a/src/Seq.Api/ResourceGroups/AppsResourceGroup.cs +++ b/src/Seq.Api/ResourceGroups/AppsResourceGroup.cs @@ -63,17 +63,6 @@ public async Task TemplateAsync(CancellationToken cancellationToken = return await GroupGetAsync("Template", cancellationToken: cancellationToken).ConfigureAwait(false); } - /// - /// Add a new app. - /// - /// The app to add. - /// A allowing the operation to be canceled. - /// The app, with server-allocated properties such as initialized. - public async Task AddAsync(AppEntity entity, CancellationToken cancellationToken = default) - { - return await GroupCreateAsync(entity, cancellationToken: cancellationToken).ConfigureAwait(false); - } - /// /// Remove an existing app. /// @@ -85,17 +74,6 @@ public async Task RemoveAsync(AppEntity entity, CancellationToken cancellationTo await Client.DeleteAsync(entity, "Self", entity, cancellationToken: cancellationToken).ConfigureAwait(false); } - /// - /// Update an existing app. - /// - /// The app to update. - /// A allowing the operation to be canceled. - /// A task indicating completion. - public async Task UpdateAsync(AppEntity entity, CancellationToken cancellationToken = default) - { - await Client.PutAsync(entity, "Self", entity, cancellationToken: cancellationToken).ConfigureAwait(false); - } - /// /// Create a new app by installing a NuGet package. /// diff --git a/src/Seq.Api/Seq.Api.csproj b/src/Seq.Api/Seq.Api.csproj index a478cb2..3d8c5cf 100644 --- a/src/Seq.Api/Seq.Api.csproj +++ b/src/Seq.Api/Seq.Api.csproj @@ -1,7 +1,7 @@ Client library for the Seq HTTP API. - 2022.1.1 + 2023.1.0 Datalust;Contributors netstandard2.0;net6.0 true @@ -15,13 +15,15 @@ - - + + - - + + + runtime; build; native; contentfiles; analyzers; buildtransitive +