Created PendingOOOStatusWorker
This commit is contained in:
parent
41a01fcf14
commit
27f78da969
@ -5,7 +5,7 @@ VisualStudioVersion = 17.6.33815.320
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "FabApprovalWorkerService", "FabApprovalWorkerService\FabApprovalWorkerService.csproj", "{5A7AB539-1A6F-4903-AB52-62BCD0BFD7B9}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FabApprovalWorkerServiceTests", "FabApprovalWorkerServiceTests\FabApprovalWorkerServiceTests.csproj", "{26BB32C6-36B9-4E02-B8DE-4262250F29E5}"
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "FabApprovalWorkerServiceTests", "FabApprovalWorkerServiceTests\FabApprovalWorkerServiceTests.csproj", "{26BB32C6-36B9-4E02-B8DE-4262250F29E5}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
|
@ -1,4 +1,4 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk.Worker">
|
||||
<Project Sdk="Microsoft.NET.Sdk.Web">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
@ -10,6 +10,10 @@
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
|
||||
<Optimize>False</Optimize>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
|
||||
<Optimize>True</Optimize>
|
||||
</PropertyGroup>
|
||||
|
||||
@ -17,17 +21,21 @@
|
||||
<PackageReference Include="CsvHelper" Version="31.0.0" />
|
||||
<PackageReference Include="Dapper" Version="2.1.28" />
|
||||
<PackageReference Include="Dapper.Contrib" Version="2.0.78" />
|
||||
<PackageReference Include="Microsoft.Data.Sqlite" Version="8.0.2" />
|
||||
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="8.0.0" />
|
||||
<PackageReference Include="Microsoft.Extensions.Hosting" Version="8.0.0" />
|
||||
<PackageReference Include="NLog" Version="5.2.8" />
|
||||
<PackageReference Include="NLog.Extensions.Logging" Version="5.3.8" />
|
||||
<PackageReference Include="Quartz" Version="3.8.1" />
|
||||
<PackageReference Include="Quartz.Extensions.Hosting" Version="3.8.1" />
|
||||
<PackageReference Include="System.Data.SqlClient" Version="4.8.6" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<EditorConfigFiles Remove="C:\Users\tuckerc\FabApprovalWorkerService\.editorconfig" />
|
||||
<EditorConfigFiles Remove=".\.editorconfig" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Include="C:\Users\tuckerc\FabApprovalWorkerService\.editorconfig" />
|
||||
<None Include=".\.editorconfig" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
|
9
FabApprovalWorkerService/Models/MonInMetricRequest.cs
Normal file
9
FabApprovalWorkerService/Models/MonInMetricRequest.cs
Normal file
@ -0,0 +1,9 @@
|
||||
namespace FabApprovalWorkerService.Models;
|
||||
|
||||
public class MonInMetricRequest
|
||||
{
|
||||
public required string resource { get; set; }
|
||||
public required DateTime dateTime { get; set; }
|
||||
public required string metricName { get; set; }
|
||||
public required double metricValue { get; set; }
|
||||
}
|
10
FabApprovalWorkerService/Models/OOOTemp.cs
Normal file
10
FabApprovalWorkerService/Models/OOOTemp.cs
Normal file
@ -0,0 +1,10 @@
|
||||
namespace FabApprovalWorkerService.Models;
|
||||
|
||||
public class OOOTemp {
|
||||
public required int ID { get; set; }
|
||||
public required int OOOUserID { get; set; }
|
||||
public int DelegatedTo { get; set; }
|
||||
public required DateTime OOOStartDate { get; set; }
|
||||
public required DateTime OOOExpirationDate { get; set; }
|
||||
public bool Processed { get; set; } = false;
|
||||
}
|
9
FabApprovalWorkerService/Models/RawMonInStatusRequest.cs
Normal file
9
FabApprovalWorkerService/Models/RawMonInStatusRequest.cs
Normal file
@ -0,0 +1,9 @@
|
||||
namespace FabApprovalWorkerService.Models;
|
||||
|
||||
public class RawMonInStatusRequest
|
||||
{
|
||||
public required string resource { get; set; }
|
||||
public required DateTime dateTime { get; set; }
|
||||
public required string statusName { get; set; }
|
||||
public required string statusValue { get; set; }
|
||||
}
|
10
FabApprovalWorkerService/Models/StatusValue.cs
Normal file
10
FabApprovalWorkerService/Models/StatusValue.cs
Normal file
@ -0,0 +1,10 @@
|
||||
namespace FabApprovalWorkerService.Models;
|
||||
|
||||
public enum StatusValue {
|
||||
Up,
|
||||
Ok,
|
||||
Warning,
|
||||
Critical,
|
||||
Down,
|
||||
Unknown
|
||||
}
|
@ -1,38 +0,0 @@
|
||||
using CsvHelper.Configuration.Attributes;
|
||||
|
||||
namespace FabApprovalWorkerService.Models;
|
||||
public class TrainingRecord {
|
||||
[Name("Item ID")]
|
||||
[Index(0)]
|
||||
public string ItemId { get; set; }
|
||||
[Name("Item Type")]
|
||||
[Index(1)]
|
||||
public string? ItemType { get; set; }
|
||||
[Name("Revision Date")]
|
||||
[Index(2)]
|
||||
public DateTime? RevisionDate { get; set; }
|
||||
[Name("Title")]
|
||||
[Index(3)]
|
||||
public string? Title { get; set; }
|
||||
[Name("User ID")]
|
||||
[Index(4)]
|
||||
public string? UserId { get; set; }
|
||||
[Name("Last Name")]
|
||||
[Index(5)]
|
||||
public string LastName { get; set; }
|
||||
[Name("First Name")]
|
||||
[Index(6)]
|
||||
public string FirstName { get; set; }
|
||||
[Name("Middle Name")]
|
||||
[Index(7)]
|
||||
public string? MiddleName { get; set; }
|
||||
[Name("Completion Status ID")]
|
||||
[Index(8)]
|
||||
public string? CompletionStatusId { get; set; }
|
||||
[Name("Completion Status")]
|
||||
[Index(9)]
|
||||
public string? CompletionStatus { get; set; }
|
||||
[Name("Completion Date")]
|
||||
[Index(10)]
|
||||
public DateTime CompletionDate { get; set; }
|
||||
}
|
8
FabApprovalWorkerService/Models/UserSubRole.cs
Normal file
8
FabApprovalWorkerService/Models/UserSubRole.cs
Normal file
@ -0,0 +1,8 @@
|
||||
namespace FabApprovalWorkerService.Models;
|
||||
|
||||
public class UserSubRole {
|
||||
public required int UserSubRoleID { get; set; }
|
||||
public required int UserID { get; set; }
|
||||
public required int SubRoleID { get; set; }
|
||||
public bool Delegated { get; set; } = false;
|
||||
}
|
@ -1,26 +1,53 @@
|
||||
using FabApprovalWorkerService.Services;
|
||||
using FabApprovalWorkerService.Workers;
|
||||
|
||||
using Microsoft.Extensions.Configuration;
|
||||
using Microsoft.Data.Sqlite;
|
||||
|
||||
using NLog.Extensions.Logging;
|
||||
|
||||
using System.Data.SqlClient;
|
||||
using Quartz;
|
||||
|
||||
using System.Data;
|
||||
using FabApprovalWorkerService.Services;
|
||||
|
||||
IHostBuilder builder = Host.CreateDefaultBuilder(args)
|
||||
.ConfigureLogging((hostContext, logging) => {
|
||||
logging.ClearProviders();
|
||||
logging.SetMinimumLevel(LogLevel.Trace);
|
||||
logging.AddNLog();
|
||||
})
|
||||
.ConfigureServices((hostContext, services) => {
|
||||
services.AddHostedService<UserCertificationUpdateWorker>();
|
||||
services.AddTransient<IDbConnection>(db => new SqlConnection(
|
||||
hostContext.Configuration.GetConnectionString("Default")));
|
||||
services.AddScoped<IDalService, DalService>();
|
||||
services.AddScoped<IUserService, UserService>();
|
||||
WebApplicationBuilder builder = WebApplication.CreateBuilder(args);
|
||||
|
||||
builder.Logging.ClearProviders();
|
||||
builder.Logging.SetMinimumLevel(LogLevel.Trace);
|
||||
builder.Logging.AddNLog();
|
||||
|
||||
builder.Services.AddHttpClient();
|
||||
|
||||
#if DEBUG
|
||||
builder.Services.AddScoped<IDbConnection>(db => new SqliteConnection(
|
||||
builder.Configuration.GetConnectionString("Default")));
|
||||
#else
|
||||
builder.Services.AddScoped<IDbConnection>(db => new SqlConnection(
|
||||
builder.Configuration.GetConnectionString("Default")));
|
||||
#endif
|
||||
|
||||
builder.Services.AddScoped<IMonInWorkerClient, MonInWorkerClient>();
|
||||
builder.Services.AddScoped<IDalService, DalService>();
|
||||
builder.Services.AddScoped<IUserService, UserService>();
|
||||
|
||||
builder.Services.AddQuartz(q => {
|
||||
JobKey updateCertDataJobKey = new JobKey("Pending OOO status job");
|
||||
q.AddJob<PendingOOOStatusWorker>(opts => opts
|
||||
.WithIdentity(updateCertDataJobKey)
|
||||
);
|
||||
q.AddTrigger(opts => opts
|
||||
.ForJob(updateCertDataJobKey)
|
||||
.WithIdentity("Pending OOO status trigger")
|
||||
.WithSimpleSchedule(x => x
|
||||
.WithIntervalInMinutes(10)
|
||||
.RepeatForever()
|
||||
)
|
||||
.StartNow()
|
||||
);
|
||||
});
|
||||
|
||||
IHost host = builder.Build();
|
||||
host.Run();
|
||||
builder.Services.AddQuartzHostedService(opt => {
|
||||
opt.WaitForJobsToComplete = true;
|
||||
});
|
||||
|
||||
WebApplication app = builder.Build();
|
||||
app.Run();
|
||||
|
@ -1,12 +1,13 @@
|
||||
{
|
||||
"$schema": "http://json.schemastore.org/launchsettings.json",
|
||||
{
|
||||
"profiles": {
|
||||
"FabApprovalWorkerService": {
|
||||
"commandName": "Project",
|
||||
"dotnetRunMessages": true,
|
||||
"environmentVariables": {
|
||||
"DOTNET_ENVIRONMENT": "Development"
|
||||
},
|
||||
"dotnetRunMessages": true,
|
||||
"nativeDebugging": true
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"$schema": "http://json.schemastore.org/launchsettings.json"
|
||||
}
|
@ -1,15 +1,21 @@
|
||||
using Dapper;
|
||||
using Dapper.Contrib.Extensions;
|
||||
|
||||
using FabApprovalWorkerService.Models;
|
||||
|
||||
using System.Data;
|
||||
|
||||
namespace FabApprovalWorkerService.Services;
|
||||
|
||||
public interface IDalService {
|
||||
Task<IEnumerable<T>> QueryAsync<T>(string sql);
|
||||
Task<bool> UpdateAsync<T>(ICollection<T> collection);
|
||||
Task<int> ExecuteAsync(string sql);
|
||||
}
|
||||
|
||||
public class DalService : IDalService {
|
||||
private static readonly int RETRIES = 3;
|
||||
private static readonly int BACKOFF_SECONDS_INTERVAL = 30;
|
||||
|
||||
private readonly IDbConnection _dbConnection;
|
||||
private readonly ILogger<DalService> _logger;
|
||||
|
||||
@ -22,35 +28,73 @@ public class DalService : IDalService {
|
||||
|
||||
public async Task<IEnumerable<T>> QueryAsync<T>(string sql) {
|
||||
if (sql is null) throw new ArgumentNullException("sql cannot be null");
|
||||
try {
|
||||
_logger.LogInformation("Attempting to perform query with {sql}", sql);
|
||||
|
||||
_dbConnection.Open();
|
||||
return await _dbConnection.QueryAsync<T>(sql);
|
||||
int remainingRetries = RETRIES;
|
||||
bool queryWasSuccessful = false;
|
||||
Exception exception = null;
|
||||
IEnumerable<T> result = new List<T>();
|
||||
while (!queryWasSuccessful && remainingRetries > 0) {
|
||||
int backoffSeconds = (RETRIES - remainingRetries--) * BACKOFF_SECONDS_INTERVAL;
|
||||
Task.Delay(backoffSeconds * 1000).Wait();
|
||||
|
||||
try {
|
||||
_logger.LogInformation("Attempting to perform query with {sql}. Remaining retries: {remainingRetries}",
|
||||
sql,
|
||||
remainingRetries);
|
||||
|
||||
using (_dbConnection) {
|
||||
result = await _dbConnection.QueryAsync<T>(sql);
|
||||
}
|
||||
|
||||
queryWasSuccessful = true;
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred while attempting to perform a query. Exception: {ex}",
|
||||
ex.Message);
|
||||
|
||||
throw;
|
||||
} finally {
|
||||
_dbConnection.Close();
|
||||
exception = ex;
|
||||
}
|
||||
}
|
||||
|
||||
public async Task<bool> UpdateAsync<T>(ICollection<T> collection) {
|
||||
if (collection is null) throw new ArgumentNullException("collection cannot be null");
|
||||
if (!queryWasSuccessful && exception is not null) {
|
||||
throw exception;
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
public async Task<int> ExecuteAsync(string sql) {
|
||||
if (sql is null) throw new ArgumentNullException("sql cannot be null");
|
||||
|
||||
int remainingRetries = RETRIES;
|
||||
bool queryWasSuccessful = false;
|
||||
Exception exception = null;
|
||||
int rowsAffected = 0;
|
||||
while (!queryWasSuccessful && remainingRetries > 0) {
|
||||
int backoffSeconds = (RETRIES - remainingRetries--) * BACKOFF_SECONDS_INTERVAL;
|
||||
Task.Delay(backoffSeconds * 1000).Wait();
|
||||
|
||||
try {
|
||||
_logger.LogInformation("Attempting to perform a bulk update");
|
||||
_logger.LogInformation("Attempting to execute {sql}. Remaining retries: {remainingRetries}",
|
||||
sql,
|
||||
remainingRetries);
|
||||
|
||||
_dbConnection.Open();
|
||||
return await _dbConnection.UpdateAsync<ICollection<T>>(collection);
|
||||
using (_dbConnection) {
|
||||
rowsAffected = await _dbConnection.ExecuteAsync(sql);
|
||||
}
|
||||
|
||||
queryWasSuccessful = true;
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred while attempting to perform a bulk update. Exception: {ex}",
|
||||
_logger.LogError("An exception occurred while attempting to execute a query. Exception: {ex}",
|
||||
ex.Message);
|
||||
|
||||
throw;
|
||||
} finally {
|
||||
_dbConnection.Close();
|
||||
exception = ex;
|
||||
}
|
||||
}
|
||||
|
||||
if (!queryWasSuccessful && exception is not null) {
|
||||
throw exception;
|
||||
}
|
||||
|
||||
return rowsAffected;
|
||||
}
|
||||
}
|
||||
|
3
FabApprovalWorkerService/Services/IMonInWorkerClient.cs
Normal file
3
FabApprovalWorkerService/Services/IMonInWorkerClient.cs
Normal file
@ -0,0 +1,3 @@
|
||||
using FabApprovalWorkerService.Models;
|
||||
|
||||
namespace FabApprovalWorkerService.Services;
|
181
FabApprovalWorkerService/Services/MonInWorkerClient.cs
Normal file
181
FabApprovalWorkerService/Services/MonInWorkerClient.cs
Normal file
@ -0,0 +1,181 @@
|
||||
using System.Text;
|
||||
using System.Text.Json;
|
||||
|
||||
using FabApprovalWorkerService.Models;
|
||||
|
||||
using static System.Net.Mime.MediaTypeNames;
|
||||
|
||||
namespace FabApprovalWorkerService.Services;
|
||||
|
||||
public interface IMonInWorkerClient {
|
||||
void PostAverage(string metricName, double metricValue);
|
||||
void PostCount(string metricName, double metricValue);
|
||||
void PostStatus(string statusName, StatusValue statusValue);
|
||||
}
|
||||
|
||||
public class MonInWorkerClient : IMonInWorkerClient {
|
||||
|
||||
private readonly IHttpClientFactory _httpClientFactory;
|
||||
private readonly IConfiguration _config;
|
||||
private readonly ILogger<MonInWorkerClient> _logger;
|
||||
|
||||
private readonly string _baseUrl;
|
||||
private readonly int _retryLimit = -1;
|
||||
private readonly int _backoffInSeconds = -1;
|
||||
|
||||
private readonly string _resource;
|
||||
|
||||
public MonInWorkerClient(IHttpClientFactory httpClientFactory,
|
||||
IConfiguration config,
|
||||
ILogger<MonInWorkerClient> logger) {
|
||||
_httpClientFactory = httpClientFactory;
|
||||
if (_httpClientFactory is null) throw new ArgumentNullException("IHttpClientFactory not injected");
|
||||
|
||||
_config = config;
|
||||
if (_config is null) throw new ArgumentNullException("IConfiguration not injected");
|
||||
|
||||
_logger = logger;
|
||||
if (_logger is null) throw new ArgumentNullException("ILogger not injected");
|
||||
|
||||
_baseUrl = _config["MonIn:workerUrl"];
|
||||
if (_baseUrl is null) throw new ArgumentNullException("MonIn:workerUrl not found in config");
|
||||
|
||||
Int32.TryParse(_config["MonIn:retries"], out _retryLimit);
|
||||
if (_retryLimit == -1) throw new ArgumentNullException("MonIn:retries not found in config");
|
||||
|
||||
Int32.TryParse(_config["MonIn:backoffInSeconds"], out _backoffInSeconds);
|
||||
if (_backoffInSeconds == -1) throw new ArgumentNullException("MonIn:backoffInSeconds not found in config");
|
||||
|
||||
_resource = _config["MonIn:resource"];
|
||||
if (_resource is null) throw new ArgumentNullException("MonIn:resource not found in config");
|
||||
}
|
||||
|
||||
public async void PostStatus(string statusName, StatusValue statusValue) {
|
||||
string url = _baseUrl + "status";
|
||||
|
||||
_logger.LogInformation("Attempting to send MonIn status request for resource {0} with name {1} and value {2} to url {3}",
|
||||
_resource,
|
||||
statusName,
|
||||
statusValue.ToString(),
|
||||
url);
|
||||
|
||||
try {
|
||||
bool success = false;
|
||||
int retries = _retryLimit;
|
||||
while (!success && retries > 0) {
|
||||
Task.Delay(TimeSpan.FromSeconds((_retryLimit - retries) * _backoffInSeconds)).Wait();
|
||||
|
||||
HttpClient httpClient = _httpClientFactory.CreateClient();
|
||||
|
||||
RawMonInStatusRequest statusRequest = new RawMonInStatusRequest() {
|
||||
resource = _resource,
|
||||
dateTime = DateTime.Now,
|
||||
statusName = statusName,
|
||||
statusValue = statusValue.ToString()
|
||||
};
|
||||
|
||||
StringContent statusRequestJson = new StringContent(JsonSerializer.Serialize(statusRequest),
|
||||
Encoding.UTF8,
|
||||
Application.Json);
|
||||
using HttpResponseMessage httpResponseMessage =
|
||||
await httpClient.PostAsync(url, statusRequestJson);
|
||||
|
||||
success = httpResponseMessage.IsSuccessStatusCode;
|
||||
retries--;
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to send MonIn status request for resource {0} with name {1} and value {2} to url {3}. Exception: {4}",
|
||||
_resource,
|
||||
statusName,
|
||||
statusValue.ToString(),
|
||||
url,
|
||||
ex.Message);
|
||||
}
|
||||
}
|
||||
|
||||
public async void PostCount(string metricName, double metricValue) {
|
||||
string url = _baseUrl + "count";
|
||||
|
||||
_logger.LogInformation("Attempting to send MonIn count request for resource {0} with name {1} and value {2} to url {3}",
|
||||
_resource,
|
||||
metricName,
|
||||
metricValue,
|
||||
url);
|
||||
|
||||
try {
|
||||
bool success = false;
|
||||
int retries = _retryLimit;
|
||||
while (!success && retries > 0) {
|
||||
Task.Delay(TimeSpan.FromSeconds((_retryLimit - retries) * _backoffInSeconds)).Wait();
|
||||
|
||||
HttpClient httpClient = _httpClientFactory.CreateClient();
|
||||
|
||||
MonInMetricRequest metricRequest = new MonInMetricRequest() {
|
||||
resource = _resource,
|
||||
dateTime = DateTime.Now,
|
||||
metricName = metricName,
|
||||
metricValue = metricValue
|
||||
};
|
||||
|
||||
StringContent metricRequestJson = new StringContent(JsonSerializer.Serialize(metricRequest),
|
||||
Encoding.UTF8,
|
||||
Application.Json);
|
||||
using HttpResponseMessage httpResponseMessage =
|
||||
await httpClient.PostAsync(url, metricRequestJson);
|
||||
|
||||
success = httpResponseMessage.IsSuccessStatusCode;
|
||||
retries--;
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to send MonIn count request for resource {0} with name {1} and value {2} to url {3}. Exception: {4}",
|
||||
_resource,
|
||||
metricName,
|
||||
metricValue,
|
||||
url,
|
||||
ex.Message);
|
||||
}
|
||||
}
|
||||
|
||||
public async void PostAverage(string metricName, double metricValue) {
|
||||
string url = _baseUrl + "average";
|
||||
|
||||
_logger.LogInformation("Attempting to send MonIn average request for resource {0} with name {1} and value {2} to url {3}",
|
||||
_resource,
|
||||
metricName,
|
||||
metricValue,
|
||||
url);
|
||||
|
||||
try {
|
||||
bool success = false;
|
||||
int retries = _retryLimit;
|
||||
while (!success && retries > 0) {
|
||||
Task.Delay(TimeSpan.FromSeconds((_retryLimit - retries) * _backoffInSeconds)).Wait();
|
||||
|
||||
HttpClient httpClient = _httpClientFactory.CreateClient();
|
||||
|
||||
MonInMetricRequest metricRequest = new MonInMetricRequest() {
|
||||
resource = _resource,
|
||||
dateTime = DateTime.Now,
|
||||
metricName = metricName,
|
||||
metricValue = metricValue
|
||||
};
|
||||
|
||||
StringContent metricRequestJson = new StringContent(JsonSerializer.Serialize(metricRequest),
|
||||
Encoding.UTF8,
|
||||
Application.Json);
|
||||
using HttpResponseMessage httpResponseMessage =
|
||||
await httpClient.PostAsync(url, metricRequestJson);
|
||||
|
||||
success = httpResponseMessage.IsSuccessStatusCode;
|
||||
retries--;
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to send MonIn average request for resource {0} with name {1} and value {2} to url {3}. Exception: {4}",
|
||||
_resource,
|
||||
metricName,
|
||||
metricValue,
|
||||
url,
|
||||
ex.Message);
|
||||
}
|
||||
}
|
||||
}
|
@ -1,64 +0,0 @@
|
||||
using CsvHelper;
|
||||
|
||||
using FabApprovalWorkerService.Models;
|
||||
|
||||
using System.Collections.Concurrent;
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
|
||||
namespace FabApprovalWorkerService.Services;
|
||||
|
||||
public interface ITrainingRecordService {
|
||||
IEnumerable<TrainingRecord> ScrapeRecordsFromCsvFile(CsvReader csvReader);
|
||||
ConcurrentDictionary<(string, string), TrainingRecord> SortAndFilterTrainingRecordsByCompletionDate(IEnumerable<TrainingRecord> trainingRecords);
|
||||
}
|
||||
public class TrainingRecordService {
|
||||
private readonly ILogger<TrainingRecordService> _logger;
|
||||
|
||||
public TrainingRecordService(ILogger<TrainingRecordService> logger) {
|
||||
_logger = logger;
|
||||
if (_logger is null) throw new ArgumentNullException("ILogger not injected");
|
||||
}
|
||||
|
||||
public IEnumerable<TrainingRecord> ScrapeTrainingRecordsFromCsvFile([DisallowNull] CsvReader csvReader) {
|
||||
if (csvReader is null) throw new ArgumentNullException("csvReader cannot be null");
|
||||
|
||||
try {
|
||||
_logger.LogInformation("Attempting to scrape training records from CSV file");
|
||||
|
||||
using (csvReader) {
|
||||
return csvReader.GetRecords<TrainingRecord>();
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to scrape training records from CSV file. Exception: {ex}",
|
||||
ex.Message);
|
||||
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
public ConcurrentDictionary<(string, string), TrainingRecord> SortAndFilterTrainingRecordsByCompletionDate([DisallowNull] IEnumerable<TrainingRecord> trainingRecords) {
|
||||
if (trainingRecords is null) throw new ArgumentNullException("trainingRecords cannot be null");
|
||||
|
||||
ConcurrentDictionary<(string, string), TrainingRecord> recordsMap = new();
|
||||
|
||||
try {
|
||||
_logger.LogInformation("Attempting to sort and filter training records");
|
||||
|
||||
IOrderedEnumerable<TrainingRecord> sortedRecords = trainingRecords.OrderByDescending(t => t.UserId)
|
||||
.ThenBy(t => t.ItemId)
|
||||
.ThenByDescending(t => t.CompletionDate);
|
||||
|
||||
foreach (TrainingRecord trainingRecord in sortedRecords) {
|
||||
if (!recordsMap.TryGetValue((trainingRecord.FirstName + trainingRecord.LastName, trainingRecord.ItemId), out TrainingRecord? existingRecord)) {
|
||||
recordsMap[(trainingRecord.FirstName + trainingRecord.LastName, trainingRecord.ItemId)] = trainingRecord;
|
||||
}
|
||||
}
|
||||
|
||||
return recordsMap;
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to sort and filter training records. Exception: {ex}", ex.Message);
|
||||
|
||||
return recordsMap;
|
||||
}
|
||||
}
|
||||
}
|
@ -1,65 +1,224 @@
|
||||
using Dapper;
|
||||
using Dapper.Contrib.Extensions;
|
||||
using FabApprovalWorkerService.Models;
|
||||
|
||||
using FabApprovalWorkerService.Models;
|
||||
|
||||
using System.Data;
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
using System.Text;
|
||||
|
||||
namespace FabApprovalWorkerService.Services;
|
||||
|
||||
public interface IUserService {
|
||||
Task<Dictionary<string, User>> GetAllUsers();
|
||||
Task<bool> UpdateUserCertificationData([DisallowNull] ICollection<User> users);
|
||||
Task<List<OOOTemp>> GetAllPendingOOOUsersAsync();
|
||||
Task<bool> IsUserAlreadyOOO(int userId);
|
||||
Task<bool> IsDelegatorAlreadyDelegatedTo(int userId);
|
||||
Task<bool> InsertDelegatedRoles(int userId);
|
||||
Task<bool> UpdateUserSubRoles(int userId, int delegatedUserId);
|
||||
Task<bool> DelegateApprovalsForUser(int userId, int delegatedUserId);
|
||||
Task<bool> FlagUserAsOOO(OOOTemp oooTemp);
|
||||
Task<bool> SetOOOTempProcessed(OOOTemp oOOTemp);
|
||||
Task<List<User>> GetAllActiveOOOUsersAsync();
|
||||
}
|
||||
|
||||
public class UserService : IUserService {
|
||||
private static readonly int PENDING_ITEM_STATUS = 0;
|
||||
private static readonly int DENITED_ITEM_STATUS = 2;
|
||||
|
||||
private readonly ILogger<UserService> _logger;
|
||||
private IDalService _dalService;
|
||||
private readonly IDalService _dalService;
|
||||
|
||||
public UserService(ILogger<UserService> logger, IDalService dalService) {
|
||||
_logger = logger;
|
||||
if (_logger is null)
|
||||
throw new ArgumentNullException("ILogger not injected");
|
||||
|
||||
_dalService = dalService;
|
||||
if (_dalService is null)
|
||||
throw new ArgumentNullException("IDalService not injected");
|
||||
}
|
||||
|
||||
public async Task<Dictionary<string, User>> GetAllUsers() {
|
||||
Dictionary<string, User> users = new Dictionary<string, User>();
|
||||
|
||||
public async Task<List<User>> GetAllActiveOOOUsersAsync() {
|
||||
try {
|
||||
_logger.LogInformation("Attempting to get all users");
|
||||
_logger.LogInformation("Attempting to get all active OOO users.");
|
||||
|
||||
string sql = "select * from users;";
|
||||
string sql = "select * from Users where OOO = 1;";
|
||||
|
||||
IEnumerable<User> enumerableUsers = await _dalService.QueryAsync<User>(sql);
|
||||
users = enumerableUsers.ToDictionary(u => u.FirstName + u.LastName, u => u);
|
||||
return (await _dalService.QueryAsync<User>(sql)).ToList();
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to get all active OOO users. Exception: {0}",
|
||||
ex.Message);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
if (!users.Any()) {
|
||||
throw new Exception("No users returned from the database");
|
||||
public async Task<List<OOOTemp>> GetAllPendingOOOUsersAsync() {
|
||||
try {
|
||||
_logger.LogInformation("Attempting to get all pending OOO users.");
|
||||
|
||||
string sql = string.Format("select * from OOOTemp where Processed = 0 and OOOStartDate <= '{0}';", DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"));
|
||||
|
||||
return (await _dalService.QueryAsync<OOOTemp>(sql)).ToList();
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to get all pending OOO users. Exception: {0}",
|
||||
ex.Message);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
public async Task<bool> IsUserAlreadyOOO(int userId) {
|
||||
try {
|
||||
_logger.LogInformation("Attempting to determine if user {userId} is already OOO", userId);
|
||||
|
||||
if (userId <= 0) {
|
||||
throw new ArgumentException(string.Format("User Id {0} is not a valid user Id", userId));
|
||||
} else {
|
||||
_logger.LogInformation("Successfully retrieved the users");
|
||||
}
|
||||
string sql = string.Format("select * from Users where OOO = 1 and UserID = {0}", userId);
|
||||
|
||||
return users;
|
||||
return (await _dalService.QueryAsync<User>(sql)).Count() > 0;
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to get all users. Exception: {ex}", ex.Message);
|
||||
return users;
|
||||
_logger.LogError("An exception occurred when attempting to determine if user {userId} is already OOO. Exception: {ex}",
|
||||
userId,
|
||||
ex.Message);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
public async Task<bool> UpdateUserCertificationData([DisallowNull] ICollection<User> users) {
|
||||
if (users is null) throw new ArgumentNullException("users cannot be null");
|
||||
|
||||
public async Task<bool> IsDelegatorAlreadyDelegatedTo(int userId) {
|
||||
try {
|
||||
_logger.LogInformation("Attempting to update user cert data");
|
||||
_logger.LogInformation("Attempting to determine if user {userId} is already OOO.", userId);
|
||||
|
||||
bool result = await _dalService.UpdateAsync(users);
|
||||
|
||||
_logger.LogInformation("User cert data updated successfully: {result}", result);
|
||||
|
||||
return result;
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to update user cert data. Exception: {ex}", ex.Message);
|
||||
if (userId <= 0) {
|
||||
_logger.LogInformation("DelegatedTo is {id}, which is not an active user Id", userId);
|
||||
return false;
|
||||
} else {
|
||||
string sql = string.Format("select * from Users where DelegatedTo = {0}", userId);
|
||||
|
||||
return (await _dalService.QueryAsync<User>(sql)).Count() > 0;
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to determine if user {userId} is already delegated to. Exception: {ex}",
|
||||
userId,
|
||||
ex.Message);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
public async Task<bool> InsertDelegatedRoles(int userId) {
|
||||
try {
|
||||
_logger.LogInformation("Attempting to add delegated roles for OOO user {id}", userId);
|
||||
|
||||
if (userId <= 0) {
|
||||
throw new ArgumentException(string.Format("User Id {0} is not a valid user Id", userId));
|
||||
} else {
|
||||
StringBuilder queryBuilder = new StringBuilder();
|
||||
|
||||
string sql = string.Format("select * from UserSubRole where UserID = {0}", userId);
|
||||
|
||||
List<UserSubRole> userSubRoles = (await _dalService.QueryAsync<UserSubRole>(sql)).ToList();
|
||||
|
||||
foreach (UserSubRole role in userSubRoles) {
|
||||
queryBuilder.Clear();
|
||||
queryBuilder.Append("insert into OOODelegatedRoles (UserID, DelegatedSubRoleID, InsertTimeStamp, Active) ");
|
||||
queryBuilder.AppendFormat("values ({0}, {1}, '{2}', 1);", userId, role.SubRoleID, DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"));
|
||||
|
||||
await _dalService.ExecuteAsync(queryBuilder.ToString());
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to add delegated roles for OOO user {userId}. Exception: {ex}",
|
||||
userId,
|
||||
ex.Message);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
public async Task<bool> UpdateUserSubRoles(int userId, int delegatedUserId) {
|
||||
try {
|
||||
_logger.LogInformation("Attempting to update sub roles for user {userId} to delegated user {delegatedUserId}",
|
||||
userId,
|
||||
delegatedUserId);
|
||||
if (userId <= 0) {
|
||||
throw new ArgumentException(string.Format("User Id {0} is not a valid user Id", userId));
|
||||
} else if (delegatedUserId <= 0) {
|
||||
throw new ArgumentException(string.Format("Delegated user Id {0} is not a valid user Id", delegatedUserId));
|
||||
} else {
|
||||
string sql = String.Format("update UserSubRole set UserID = {0}, Delegated = 1 where UserID = {1}", delegatedUserId, userId);
|
||||
|
||||
await _dalService.ExecuteAsync(sql);
|
||||
|
||||
return true;
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to update sub roles for user {userId} to delegated user {delegatedUserId}. Exception: {ex}",
|
||||
userId,
|
||||
delegatedUserId,
|
||||
ex.Message);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
public async Task<bool> DelegateApprovalsForUser(int userId, int delegatedUserId) {
|
||||
try {
|
||||
_logger.LogInformation("Attempting to delegate approvals for user {userId} to delegated user {delegatedUserId}",
|
||||
userId,
|
||||
delegatedUserId);
|
||||
if (userId <= 0) {
|
||||
throw new ArgumentException(string.Format("User Id {0} is not a valid user Id", userId));
|
||||
} else if (delegatedUserId <= 0) {
|
||||
throw new ArgumentException(string.Format("Delegated user Id {0} is not a valid user Id", delegatedUserId));
|
||||
} else {
|
||||
string sql = String.Format("update Approval set UserID = {0}, Delegated = 1 where UserID = {1} and (ItemStatus = {2} or ItemStatus = {3})",
|
||||
delegatedUserId,
|
||||
userId,
|
||||
PENDING_ITEM_STATUS,
|
||||
DENITED_ITEM_STATUS);
|
||||
|
||||
await _dalService.ExecuteAsync(sql);
|
||||
|
||||
return true;
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to delegate approvals for user {userId} to delegated user {delegatedUserId}. Exception: {ex}",
|
||||
userId,
|
||||
delegatedUserId,
|
||||
ex.Message);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
public async Task<bool> FlagUserAsOOO(OOOTemp oooTemp) {
|
||||
try {
|
||||
if (oooTemp is null) throw new ArgumentNullException("oooTemp cannot be null");
|
||||
|
||||
_logger.LogInformation("Attempting to flag user {id} as OOO", oooTemp.OOOUserID);
|
||||
|
||||
StringBuilder queryBuilder = new StringBuilder();
|
||||
queryBuilder.Append("update Users set OOO = 1, ");
|
||||
queryBuilder.AppendFormat("OOOStartDate = '{0}', ", oooTemp.OOOStartDate);
|
||||
queryBuilder.AppendFormat("OOOExpirationDate = '{0}', ", oooTemp.OOOExpirationDate);
|
||||
queryBuilder.AppendFormat("DelegatedTo = {0} ", oooTemp.DelegatedTo);
|
||||
queryBuilder.AppendFormat("where UserID = {0}", oooTemp.OOOUserID);
|
||||
|
||||
return (await _dalService.ExecuteAsync(queryBuilder.ToString())) > 0;
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to flag user as OOO. Exception: {ex}",
|
||||
ex.Message);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
public async Task<bool> SetOOOTempProcessed(OOOTemp oooTemp) {
|
||||
try {
|
||||
if (oooTemp is null) throw new ArgumentNullException("oooTemp cannot be null");
|
||||
|
||||
_logger.LogInformation("Attempting to set OOOTemp {id} Processed to {processed}", oooTemp.ID, oooTemp.Processed);
|
||||
|
||||
string sql = string.Format("update OOOTemp set Processed = {0} where ID = {1}", oooTemp.Processed, oooTemp.ID);
|
||||
|
||||
return (await _dalService.ExecuteAsync(sql)) > 0;
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to flag user as OOO. Exception: {ex}",
|
||||
ex.Message);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -0,0 +1,15 @@
|
||||
drop table if exists Approval;
|
||||
|
||||
create table Approval (
|
||||
ApprovalID integer primary key,
|
||||
IssueID integer not null,
|
||||
UserID integer not null,
|
||||
ItemStatus integer default 0,
|
||||
Delegated integer default 0
|
||||
);
|
||||
|
||||
insert into Approval (IssueID, UserID)
|
||||
values (1, 15),
|
||||
(2, 34),
|
||||
(3, 2),
|
||||
(4, 19);
|
@ -0,0 +1,9 @@
|
||||
drop table if exists OOODelegatedRoles;
|
||||
|
||||
create table OOODelegatedRoles (
|
||||
OOOID integer primary key,
|
||||
UserID integer not null,
|
||||
DelegatedSubRoleID integer not null,
|
||||
InsertTimeStamp text not null,
|
||||
Active integer default 0
|
||||
);
|
16
FabApprovalWorkerService/SetupScripts/CreateOOOTempTable.sql
Normal file
16
FabApprovalWorkerService/SetupScripts/CreateOOOTempTable.sql
Normal file
@ -0,0 +1,16 @@
|
||||
drop table if exists OOOTemp;
|
||||
|
||||
create table OOOTemp (
|
||||
ID INTEGER primary key,
|
||||
OOOUserID INTEGER not null,
|
||||
DelegatedTo INTEGER not null,
|
||||
OOOStartDate TEXT not null,
|
||||
OOOExpirationDate TEXT not null,
|
||||
Processed INTEGER default 0
|
||||
);
|
||||
|
||||
insert into OOOTemp (OOOUserID, DelegatedTo, OOOStartDate, OOOExpirationDate)
|
||||
values (15, 22, '2024-03-19 00:00:00', '2024-04-19 00:00:00'),
|
||||
(34, 19, '2024-03-19 00:00:00', '2024-04-19 00:00:00'),
|
||||
(2, 15, '2024-03-19 00:00:00', '2024-04-01 00:00:00'),
|
||||
(19, 18, '2024-04-01 00:00:00', '2033-06-01 00:00:00');
|
@ -0,0 +1,14 @@
|
||||
drop table if exists UserSubRole;
|
||||
|
||||
create table UserSubRole (
|
||||
UserSubRoleID integer primary key,
|
||||
UserID integer not null,
|
||||
SubRoleID integer not null,
|
||||
Delegated integer default 0
|
||||
);
|
||||
|
||||
insert into UserSubRole (UserID, SubRoleID)
|
||||
values (15, 1),
|
||||
(34, 19),
|
||||
(2, 5),
|
||||
(19, 3);
|
73
FabApprovalWorkerService/SetupScripts/CreateUserTable.sql
Normal file
73
FabApprovalWorkerService/SetupScripts/CreateUserTable.sql
Normal file
@ -0,0 +1,73 @@
|
||||
drop table if exists Users;
|
||||
|
||||
create table Users (
|
||||
UserID INTEGER primary key,
|
||||
LoginID TEXT not null,
|
||||
FirstName TEXT not null,
|
||||
LastName TEXT not null,
|
||||
Email TEXT not null,
|
||||
Notify INTEGER default 0,
|
||||
IsAdmin INTEGER default 0,
|
||||
OOO INTEGER default 0,
|
||||
OOOStartDate TEXT,
|
||||
OOOExpirationDate TEXT,
|
||||
DelegatedTo INTEGER,
|
||||
CanViewITAR INTEGER default 1,
|
||||
IsManager INTEGER default 0,
|
||||
IsCleansCertified INTEGER default 0,
|
||||
IsAnyLevelCertified INTEGER default 0,
|
||||
IsPackagingLabelingCertified INTEGER default 0,
|
||||
IsEpiProCertified INTEGER default 0,
|
||||
IsFqaCertified INTEGER default 0,
|
||||
IsFqaAssessmentCertified INTEGER default 0,
|
||||
IsActive INTEGER default 1
|
||||
);
|
||||
|
||||
insert into Users (LoginID, FirstName, LastName, Email)
|
||||
values ('AsRa', 'Ra', 'As', 'email'),
|
||||
('AuTr', 'Tr', 'Au', 'email'),
|
||||
('AyNi', 'Ni', 'Ay', 'email'),
|
||||
('BaGr', 'Gr', 'Ba', 'email'),
|
||||
('BaGu', 'Gu', 'Ba', 'email'),
|
||||
('BeTo', 'To', 'Be', 'email'),
|
||||
('BeBr', 'Br', 'Be', 'email'),
|
||||
('BrKy', 'Ky', 'Br', 'email'),
|
||||
('CaSh', 'Sh', 'Ca', 'email'),
|
||||
('CaRe', 'Re', 'Ca', 'email'),
|
||||
('CaSt', 'St', 'Ca', 'email'),
|
||||
('ClNi', 'Ni', 'Cl', 'email'),
|
||||
('DaMi', 'Mi', 'Da', 'email'),
|
||||
('FuJe', 'Je', 'Fu', 'email'),
|
||||
('GaAl', 'Al', 'Ga', 'email'),
|
||||
('GoAs', 'As', 'Go', 'email'),
|
||||
('GoRu', 'Ru', 'Go', 'email'),
|
||||
('GoOr', 'Or', 'Go', 'email'),
|
||||
('HaAn', 'An', 'Ha', 'email'),
|
||||
('HaPa', 'Pa', 'Ha', 'email'),
|
||||
('HoJu', 'Ju', 'Ho', 'email'),
|
||||
('HoDe', 'De', 'Ho', 'email'),
|
||||
('HoVi', 'Vi', 'Ho', 'email'),
|
||||
('InCa', 'Ca', 'In', 'email'),
|
||||
('JaMi', 'Mi', 'Ja', 'email'),
|
||||
('LeTh', 'Th', 'Le', 'email'),
|
||||
('LeHa', 'Ha', 'Le', 'email'),
|
||||
('LoAn', 'An', 'Lo', 'email'),
|
||||
('LoCh', 'Ch', 'Lo', 'email'),
|
||||
('LuDa', 'Da', 'Lu', 'email'),
|
||||
('MaBr', 'Br', 'Ma', 'email'),
|
||||
('MaDa', 'Da', 'Ma', 'email'),
|
||||
('MaDo', 'Do', 'Ma', 'email'),
|
||||
('McJu', 'Ju', 'Mc', 'email'),
|
||||
('MeGi', 'Gi', 'Me', 'email'),
|
||||
('MiSh', 'Sh', 'Mi', 'email'),
|
||||
('MoBa', 'Ba', 'Mo', 'email'),
|
||||
('MuTi', 'Ti', 'Mu', 'email'),
|
||||
('OtMa', 'Ma', 'Ot', 'email'),
|
||||
('PeAl', 'Al', 'Pe', 'email'),
|
||||
('RiCy', 'Cy', 'Ri', 'email'),
|
||||
('RoAp', 'Ap', 'Ro', 'email'),
|
||||
('SoAb', 'Ab', 'So', 'email'),
|
||||
('VaMi', 'Mi', 'Va', 'email'),
|
||||
('VuTh', 'Th', 'Va', 'email'),
|
||||
('WeWi', 'Wi', 'We', 'email'),
|
||||
('ZaNi', 'Ni', 'Za', 'email');
|
7
FabApprovalWorkerService/SetupScripts/SetupDb.bat
Normal file
7
FabApprovalWorkerService/SetupScripts/SetupDb.bat
Normal file
@ -0,0 +1,7 @@
|
||||
md D:\FabApprovalWorkerService
|
||||
sqlite3 D:\FabApprovalWorkerService\LocalDb.db < .\CreateUserTable.sql
|
||||
sqlite3 D:\FabApprovalWorkerService\LocalDb.db < .\CreateOOOTempTable.sql
|
||||
sqlite3 D:\FabApprovalWorkerService\LocalDb.db < .\CreateUserSubRoleTable.sql
|
||||
sqlite3 D:\FabApprovalWorkerService\LocalDb.db < .\CreateOOODelegatedRolesTable.sql
|
||||
sqlite3 D:\FabApprovalWorkerService\LocalDb.db < .\CreateApprovalTable.sql
|
||||
pause
|
81
FabApprovalWorkerService/Workers/PendingOOOStatusWorker.cs
Normal file
81
FabApprovalWorkerService/Workers/PendingOOOStatusWorker.cs
Normal file
@ -0,0 +1,81 @@
|
||||
using FabApprovalWorkerService.Models;
|
||||
using FabApprovalWorkerService.Services;
|
||||
|
||||
using Quartz;
|
||||
|
||||
using System.Text;
|
||||
|
||||
namespace FabApprovalWorkerService.Workers;
|
||||
|
||||
public sealed class PendingOOOStatusWorker : IJob {
|
||||
private readonly ILogger<PendingOOOStatusWorker> _logger;
|
||||
private readonly IMonInWorkerClient _monInClient;
|
||||
private readonly IUserService _userService;
|
||||
|
||||
public PendingOOOStatusWorker(ILogger<PendingOOOStatusWorker> logger,
|
||||
IMonInWorkerClient monInClient,
|
||||
IUserService userService) {
|
||||
_logger = logger;
|
||||
if (_logger is null)
|
||||
throw new ArgumentNullException("ILogger not injected");
|
||||
|
||||
_monInClient = monInClient;
|
||||
if (_monInClient is null) {
|
||||
throw new ArgumentNullException("IMonInWorkerClient not injected");
|
||||
}
|
||||
|
||||
_userService = userService;
|
||||
if (_userService is null)
|
||||
throw new ArgumentNullException("IUserService not injected");
|
||||
}
|
||||
|
||||
public async Task Execute(IJobExecutionContext context) {
|
||||
DateTime start = DateTime.Now;
|
||||
bool isInternalError = false;
|
||||
StringBuilder errorMessage = new();
|
||||
string metricName = "PendingOOOStatusWorker";
|
||||
|
||||
try {
|
||||
_logger.LogInformation("Attempting to set OOO status for users pending earlier than now");
|
||||
|
||||
List<OOOTemp> pendingOOOUsers = await _userService.GetAllPendingOOOUsersAsync();
|
||||
|
||||
foreach (OOOTemp oooTemp in pendingOOOUsers) {
|
||||
Task<bool> userAlreadyOOO = _userService.IsUserAlreadyOOO(oooTemp.OOOUserID);
|
||||
Task<bool> delegateAlreadyADelegate = _userService.IsDelegatorAlreadyDelegatedTo(oooTemp.DelegatedTo);
|
||||
|
||||
if (!userAlreadyOOO.Result && !delegateAlreadyADelegate.Result) {
|
||||
List<Task> enableOOOTasks = new();
|
||||
enableOOOTasks.Add(_userService.InsertDelegatedRoles(oooTemp.OOOUserID));
|
||||
enableOOOTasks.Add(_userService.UpdateUserSubRoles(oooTemp.OOOUserID, oooTemp.DelegatedTo));
|
||||
enableOOOTasks.Add(_userService.DelegateApprovalsForUser(oooTemp.OOOUserID, oooTemp.DelegatedTo));
|
||||
Task enableOOOTasksResult = Task.WhenAll(enableOOOTasks);
|
||||
|
||||
if (enableOOOTasksResult.IsCompletedSuccessfully) {
|
||||
bool userIsNowOOO = await _userService.FlagUserAsOOO(oooTemp);
|
||||
if (userIsNowOOO) {
|
||||
oooTemp.Processed = true;
|
||||
await _userService.SetOOOTempProcessed(oooTemp);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
_logger.LogInformation("Successfully set OOO status for users pending earlier than now");
|
||||
} catch (Exception ex) {
|
||||
_logger.LogError("An exception occurred when attempting to set OOO status for users pending earlier than now. Exception: {ex}",
|
||||
ex.StackTrace);
|
||||
isInternalError = true;
|
||||
} finally {
|
||||
DateTime end = DateTime.Now;
|
||||
double latencyInMS = (end - start).TotalMilliseconds;
|
||||
_monInClient.PostAverage(metricName + "Latency", latencyInMS);
|
||||
|
||||
if (isInternalError) {
|
||||
_monInClient.PostStatus(metricName, StatusValue.Critical);
|
||||
} else {
|
||||
_monInClient.PostStatus(metricName, StatusValue.Ok);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,18 +0,0 @@
|
||||
namespace FabApprovalWorkerService.Workers;
|
||||
|
||||
public class UserCertificationUpdateWorker : BackgroundService {
|
||||
private readonly ILogger<UserCertificationUpdateWorker> _logger;
|
||||
|
||||
public UserCertificationUpdateWorker(ILogger<UserCertificationUpdateWorker> logger) {
|
||||
_logger = logger;
|
||||
}
|
||||
|
||||
protected override async Task ExecuteAsync(CancellationToken stoppingToken) {
|
||||
while (!stoppingToken.IsCancellationRequested) {
|
||||
if (_logger.IsEnabled(LogLevel.Information)) {
|
||||
_logger.LogInformation("UserCertificationUpdateWorker running at: {time}", DateTimeOffset.Now);
|
||||
}
|
||||
await Task.Delay(1000, stoppingToken);
|
||||
}
|
||||
}
|
||||
}
|
@ -6,6 +6,10 @@
|
||||
}
|
||||
},
|
||||
"ConnectionStrings": {
|
||||
"Default": "Data Source=MESTSV02EC.infineon.com\\TEST1,50572;Integrated Security=False;Initial Catalog=FabApprovalSystem;User ID=fab_approval_admin_test;Password=Fab_approval_admin_test2023!;Connect Timeout=15;Encrypt=False;TrustServerCertificate=False; Min Pool Size=15"
|
||||
"Default": "Data Source=D:\\FabApprovalWorkerService\\LocalDb.db"
|
||||
},
|
||||
"MonIn": {
|
||||
"resource": "FAB_APPROVAL_WORKER_SERVICE_MES_OP_FE_TEST",
|
||||
"workerUrl": "https://mestsa008.infineon.com:7851/"
|
||||
}
|
||||
}
|
||||
|
@ -4,5 +4,14 @@
|
||||
"Default": "Information",
|
||||
"Microsoft.Hosting.Lifetime": "Information"
|
||||
}
|
||||
},
|
||||
"ConnectionStrings": {
|
||||
"Default": "Data Source=MESTSV02EC.infineon.com\\TEST1,50572;Integrated Security=False;Initial Catalog=FabApprovalSystem;User ID=fab_approval_admin_test;Password=Fab_approval_admin_test2023!;Connect Timeout=15;Encrypt=False;TrustServerCertificate=False; Min Pool Size=15"
|
||||
},
|
||||
"MonIn": {
|
||||
"resource": "FAB_APPROVAL_WORKER_SERVICE_MES_OP_FE",
|
||||
"workerUrl": "https://messa014.infineon.com:7851/",
|
||||
"retries": 3,
|
||||
"backoffInSeconds": 30
|
||||
}
|
||||
}
|
||||
|
@ -14,7 +14,7 @@
|
||||
xsi:type="File"
|
||||
fileName="d:\logs\FabApprovalWorkerService\log.txt"
|
||||
archiveFilename="d:\logs\FabApprovalWorkerService\archive\log-${shortdate}.txt"
|
||||
maxArchiveFiles="15"
|
||||
maxArchiveFiles="30"
|
||||
archiveEvery="Day"
|
||||
/>
|
||||
<target
|
||||
|
@ -1,112 +0,0 @@
|
||||
using FabApprovalWorkerService.Models;
|
||||
using FabApprovalWorkerService.Services;
|
||||
|
||||
using Microsoft.Extensions.Logging;
|
||||
|
||||
using Moq;
|
||||
|
||||
using System.Collections.Concurrent;
|
||||
|
||||
namespace FabApprovalWorkerServiceTests;
|
||||
public class TrainingRecordServiceTests {
|
||||
private static readonly ILogger<TrainingRecordService> MOCK_LOGGER = Mock.Of<ILogger<TrainingRecordService>>();
|
||||
|
||||
private TrainingRecordService _trainingRecordService;
|
||||
|
||||
[SetUp]
|
||||
public void Setup() {
|
||||
_trainingRecordService = new TrainingRecordService(MOCK_LOGGER);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void ScrapeTrainingRecordsWithNullCsvReaderShouldThrowException() {
|
||||
Assert.Throws<ArgumentNullException>(() => _trainingRecordService.ScrapeTrainingRecordsFromCsvFile(null));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void SortAndFilterWithNullArgShouldThrowException() {
|
||||
Assert.Throws<ArgumentNullException>(() => _trainingRecordService.SortAndFilterTrainingRecordsByCompletionDate(null));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void SortAndFilterShouldProduceExpectedResult() {
|
||||
List<TrainingRecord> trainingRecords = new List<TrainingRecord>() {
|
||||
new TrainingRecord() {
|
||||
ItemId = "item1",
|
||||
UserId = "User1",
|
||||
LastName = "LastName1",
|
||||
FirstName = "FirstName1",
|
||||
CompletionDate = DateTime.Now
|
||||
},
|
||||
new TrainingRecord() {
|
||||
ItemId = "item1",
|
||||
UserId = "User2",
|
||||
LastName = "LastName2",
|
||||
FirstName = "FirstName2",
|
||||
CompletionDate = DateTime.Now
|
||||
},
|
||||
new TrainingRecord() {
|
||||
ItemId = "item1",
|
||||
UserId = "User1",
|
||||
LastName = "LastName1",
|
||||
FirstName = "FirstName1",
|
||||
CompletionDate = DateTime.Now.AddDays(-1)
|
||||
},
|
||||
new TrainingRecord() {
|
||||
ItemId = "item1",
|
||||
UserId = "User2",
|
||||
LastName = "LastName2",
|
||||
FirstName = "FirstName2",
|
||||
CompletionDate = DateTime.Now.AddDays(-1)
|
||||
},
|
||||
new TrainingRecord() {
|
||||
ItemId = "item1",
|
||||
UserId = "User1",
|
||||
LastName = "LastName1",
|
||||
FirstName = "FirstName1",
|
||||
CompletionDate = DateTime.Now.AddDays(-30)
|
||||
},
|
||||
new TrainingRecord() {
|
||||
ItemId = "item1",
|
||||
UserId = "User2",
|
||||
LastName = "LastName2",
|
||||
FirstName = "FirstName2",
|
||||
CompletionDate = DateTime.Now.AddDays(-30)
|
||||
},
|
||||
new TrainingRecord() {
|
||||
ItemId = "item2",
|
||||
UserId = "User1",
|
||||
LastName = "LastName1",
|
||||
FirstName = "FirstName1",
|
||||
CompletionDate = DateTime.Now
|
||||
},
|
||||
new TrainingRecord() {
|
||||
ItemId = "item2",
|
||||
UserId = "User2",
|
||||
LastName = "LastName2",
|
||||
FirstName = "FirstName2",
|
||||
CompletionDate = DateTime.Now
|
||||
},
|
||||
new TrainingRecord() {
|
||||
ItemId = "item2",
|
||||
UserId = "User1",
|
||||
LastName = "LastName1",
|
||||
FirstName = "FirstName1",
|
||||
CompletionDate = DateTime.Now.AddDays(-5)
|
||||
},
|
||||
new TrainingRecord() {
|
||||
ItemId = "item2",
|
||||
UserId = "User2",
|
||||
LastName = "LastName2",
|
||||
FirstName = "FirstName2",
|
||||
CompletionDate = DateTime.Now.AddDays(-5)
|
||||
}
|
||||
};
|
||||
|
||||
ConcurrentDictionary<(string, string), TrainingRecord> actualRecords = _trainingRecordService.SortAndFilterTrainingRecordsByCompletionDate(trainingRecords);
|
||||
|
||||
Assert.That(actualRecords.Count, Is.EqualTo(4));
|
||||
Assert.That(actualRecords[("FirstName1LastName1", "item1")].CompletionDate, Is.GreaterThan(DateTime.Now.AddDays(-1)));
|
||||
Assert.That(actualRecords[("FirstName2LastName2", "item2")].CompletionDate, Is.GreaterThan(DateTime.Now.AddDays(-5)));
|
||||
}
|
||||
}
|
@ -1,4 +1,3 @@
|
||||
using Dapper;
|
||||
using Dapper.Contrib.Extensions;
|
||||
|
||||
using FabApprovalWorkerService.Models;
|
||||
@ -7,9 +6,6 @@ using FabApprovalWorkerService.Services;
|
||||
using Microsoft.Extensions.Logging;
|
||||
|
||||
using Moq;
|
||||
using Moq.Dapper;
|
||||
|
||||
using System.Data;
|
||||
|
||||
namespace FabApprovalWorkerServiceTests;
|
||||
|
||||
@ -24,7 +20,7 @@ public class UserServiceTests {
|
||||
LastName = "flintstone",
|
||||
Email = "fred.flintstone@email.com",
|
||||
IsAdmin = true,
|
||||
OOO = false,
|
||||
OOO = true,
|
||||
CanViewITAR = true,
|
||||
IsManager = false
|
||||
},
|
||||
@ -35,12 +31,27 @@ public class UserServiceTests {
|
||||
LastName = "rubble",
|
||||
Email = "barney.rubble@email.com",
|
||||
IsAdmin = false,
|
||||
OOO = false,
|
||||
OOO = true,
|
||||
CanViewITAR = true,
|
||||
IsManager = false
|
||||
}
|
||||
};
|
||||
|
||||
private static readonly IEnumerable<OOOTemp> MOCK_OOO_TEMPS = new List<OOOTemp>() {
|
||||
new OOOTemp() {
|
||||
ID = 1,
|
||||
OOOUserID = 1,
|
||||
OOOExpirationDate = DateTime.Now,
|
||||
OOOStartDate = DateTime.Now,
|
||||
},
|
||||
new OOOTemp() {
|
||||
ID = 2,
|
||||
OOOUserID = 2,
|
||||
OOOExpirationDate = DateTime.Now,
|
||||
OOOStartDate = DateTime.Now,
|
||||
}
|
||||
};
|
||||
|
||||
Mock<IDalService> _mockDalService;
|
||||
|
||||
public UserService _userService;
|
||||
@ -48,27 +59,273 @@ public class UserServiceTests {
|
||||
[SetUp]
|
||||
public void Setup() {
|
||||
_mockDalService = new Mock<IDalService>();
|
||||
|
||||
_mockDalService.Setup(d => d.QueryAsync<User>(It.IsAny<string>())).Returns(Task.FromResult(MOCK_USERS));
|
||||
_mockDalService.Setup(d => d.UpdateAsync<User>(It.IsAny<ICollection<User>>())).Returns(Task.FromResult(true));
|
||||
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task GetAllUsersShouldReturnMockUsers() {
|
||||
Dictionary<string, User> users = await _userService.GetAllUsers();
|
||||
public void UserServiceWithNullLoggerShouldThrowException() {
|
||||
_mockDalService = new Mock<IDalService>();
|
||||
|
||||
Assert.Throws<ArgumentNullException>(() => new UserService(null, _mockDalService.Object));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void UserServiceWithNullDalServiceShouldThrowException() {
|
||||
Assert.Throws<ArgumentNullException>(() => new UserService(MOCK_LOGGER, null));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task GetAllActiveOOOUsersShouldReturnMockUsers() {
|
||||
_mockDalService.Setup(d => d.QueryAsync<User>(It.IsAny<string>())).Returns(Task.FromResult(MOCK_USERS));
|
||||
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
List<User> users = await _userService.GetAllActiveOOOUsersAsync();
|
||||
|
||||
Assert.True(users.Count() == 2);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void UpdateUserCertificateDataWithNullListShouldThrowException() {
|
||||
Assert.ThrowsAsync<ArgumentNullException>(async () => await _userService.UpdateUserCertificationData(null));
|
||||
public async Task GetAllPendingOOOUsersShouldReturnMockOOOTemps() {
|
||||
_mockDalService.Setup(d => d.QueryAsync<OOOTemp>(It.IsAny<string>())).Returns(Task.FromResult(MOCK_OOO_TEMPS));
|
||||
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
List<OOOTemp> oooTemps = await _userService.GetAllPendingOOOUsersAsync();
|
||||
|
||||
Assert.True(oooTemps.Count() == 2);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task UpdateUserCertificationDataShouldReturnTrue() {
|
||||
bool result = await _userService.UpdateUserCertificationData(MOCK_USERS.ToList());
|
||||
Assert.True(result);
|
||||
public async Task IsUserAlreadyOOOWithInvalidUserIdShouldThrowException() {
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
Assert.ThrowsAsync<ArgumentException>(async Task () => await _userService.IsUserAlreadyOOO(0));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task IsUserAlreadyOOOWithNoUsersShouldReturnFalse() {
|
||||
IEnumerable<User> emptyUsers = new List<User>();
|
||||
|
||||
_mockDalService.Setup(d => d.QueryAsync<User>(It.IsAny<string>())).Returns(Task.FromResult(emptyUsers));
|
||||
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
bool actual = await _userService.IsUserAlreadyOOO(2);
|
||||
|
||||
Assert.False(actual);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task IsUserAlreadyOOOWithSomeUsersShouldReturnTrue() {
|
||||
IEnumerable<User> emptyUsers = new List<User>();
|
||||
|
||||
_mockDalService.Setup(d => d.QueryAsync<User>(It.IsAny<string>())).Returns(Task.FromResult(MOCK_USERS));
|
||||
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
bool actual = await _userService.IsUserAlreadyOOO(2);
|
||||
|
||||
Assert.True(actual);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task IsDelegatorAlreadyDelegatedToWithInvalidUserIdShouldReturnFalse() {
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
Assert.False(await _userService.IsDelegatorAlreadyDelegatedTo(0));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task IsDelegatorAlreadyDelegatedToWithNoUsersShouldReturnFalse() {
|
||||
IEnumerable<User> emptyUsers = new List<User>();
|
||||
|
||||
_mockDalService.Setup(d => d.QueryAsync<User>(It.IsAny<string>())).Returns(Task.FromResult(emptyUsers));
|
||||
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
bool actual = await _userService.IsDelegatorAlreadyDelegatedTo(2);
|
||||
|
||||
Assert.False(actual);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task IsDelegatorAlreadyDelegatedToWithSomeUsersShouldReturnTrue() {
|
||||
IEnumerable<User> emptyUsers = new List<User>();
|
||||
|
||||
_mockDalService.Setup(d => d.QueryAsync<User>(It.IsAny<string>())).Returns(Task.FromResult(MOCK_USERS));
|
||||
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
bool actual = await _userService.IsDelegatorAlreadyDelegatedTo(2);
|
||||
|
||||
Assert.True(actual);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task InsertDelegatedRolesWithInvalidUserIdShouldThrowException() {
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
Assert.ThrowsAsync<ArgumentException>(async Task () => await _userService.InsertDelegatedRoles(0));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task InsertDelegatedRolesWithValidUserIdShouldReturnTrue() {
|
||||
IEnumerable<UserSubRole> userSubRoles = new List<UserSubRole>() {
|
||||
new UserSubRole() {
|
||||
UserSubRoleID = 1,
|
||||
UserID = 1,
|
||||
SubRoleID = 1
|
||||
},
|
||||
new UserSubRole() {
|
||||
UserSubRoleID = 2,
|
||||
UserID = 2,
|
||||
SubRoleID = 2
|
||||
}
|
||||
};
|
||||
|
||||
_mockDalService.Setup(d => d.QueryAsync<UserSubRole>(It.IsAny<string>())).Returns(Task.FromResult(userSubRoles));
|
||||
_mockDalService.Setup(d => d.ExecuteAsync(It.IsAny<string>())).Returns(Task.FromResult(1));
|
||||
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
bool actual = await _userService.InsertDelegatedRoles(2);
|
||||
|
||||
Assert.True(actual);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task UpdateUserSubRolesWithInvalidUserIdShouldThrowException() {
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
Assert.ThrowsAsync<ArgumentException>(async Task () => await _userService.UpdateUserSubRoles(0, 2));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task UpdateUserSubRolesWithInvalidDelegateIdShouldThrowException() {
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
Assert.ThrowsAsync<ArgumentException>(async Task () => await _userService.UpdateUserSubRoles(2, 0));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task UpdateUserSubRolesWithValidUserIdShouldReturnTrue() {
|
||||
_mockDalService.Setup(d => d.ExecuteAsync(It.IsAny<string>())).Returns(Task.FromResult(1));
|
||||
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
bool actual = await _userService.UpdateUserSubRoles(2, 2);
|
||||
|
||||
Assert.True(actual);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task DelegateApprovalsForUserWithInvalidUserIdShouldThrowException() {
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
Assert.ThrowsAsync<ArgumentException>(async Task () => await _userService.DelegateApprovalsForUser(0, 2));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task DelegateApprovalsForUserWithInvalidDelegateIdShouldThrowException() {
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
Assert.ThrowsAsync<ArgumentException>(async Task () => await _userService.DelegateApprovalsForUser(2, 0));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task DelegateApprovalsForUserWithValidUserIdShouldReturnTrue() {
|
||||
_mockDalService.Setup(d => d.ExecuteAsync(It.IsAny<string>())).Returns(Task.FromResult(1));
|
||||
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
bool actual = await _userService.DelegateApprovalsForUser(2, 2);
|
||||
|
||||
Assert.True(actual);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task FlagUserAsOOOWithNullOOOTempShouldThrowException() {
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
Assert.ThrowsAsync<ArgumentNullException>(async Task () => await _userService.FlagUserAsOOO(null));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task FlagUserAsOOOWithValidOOOTempShouldReturnTrue() {
|
||||
OOOTemp oooTemp = new OOOTemp() {
|
||||
ID = 1,
|
||||
OOOUserID = 1,
|
||||
OOOStartDate = DateTime.Now,
|
||||
OOOExpirationDate = DateTime.Now
|
||||
};
|
||||
|
||||
_mockDalService.Setup(d => d.ExecuteAsync(It.IsAny<string>())).Returns(Task.FromResult(1));
|
||||
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
bool actual = await _userService.FlagUserAsOOO(oooTemp);
|
||||
|
||||
Assert.True(actual);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task FlagUserAsOOOWithInvalidUserIdShouldReturnFalse() {
|
||||
OOOTemp oooTemp = new OOOTemp() {
|
||||
ID = 1,
|
||||
OOOUserID = 1,
|
||||
OOOStartDate = DateTime.Now,
|
||||
OOOExpirationDate = DateTime.Now
|
||||
};
|
||||
|
||||
_mockDalService.Setup(d => d.ExecuteAsync(It.IsAny<string>())).Returns(Task.FromResult(0));
|
||||
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
bool actual = await _userService.FlagUserAsOOO(oooTemp);
|
||||
|
||||
Assert.False(actual);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task SetOOOTempProcessedWithNullOOOTempShouldThrowException() {
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
Assert.ThrowsAsync<ArgumentNullException>(async Task () => await _userService.SetOOOTempProcessed(null));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task SetOOOTempProcessedWithValidOOOTempShouldReturnTrue() {
|
||||
OOOTemp oooTemp = new OOOTemp() {
|
||||
ID = 1,
|
||||
OOOUserID = 1,
|
||||
OOOStartDate = DateTime.Now,
|
||||
OOOExpirationDate = DateTime.Now
|
||||
};
|
||||
|
||||
_mockDalService.Setup(d => d.ExecuteAsync(It.IsAny<string>())).Returns(Task.FromResult(1));
|
||||
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
bool actual = await _userService.SetOOOTempProcessed(oooTemp);
|
||||
|
||||
Assert.True(actual);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public async Task SetOOOTempProcessedWithInvalidIdShouldReturnFalse() {
|
||||
OOOTemp oooTemp = new OOOTemp() {
|
||||
ID = 1,
|
||||
OOOUserID = 1,
|
||||
OOOStartDate = DateTime.Now,
|
||||
OOOExpirationDate = DateTime.Now
|
||||
};
|
||||
|
||||
_mockDalService.Setup(d => d.ExecuteAsync(It.IsAny<string>())).Returns(Task.FromResult(0));
|
||||
|
||||
_userService = new UserService(MOCK_LOGGER, _mockDalService.Object);
|
||||
|
||||
bool actual = await _userService.SetOOOTempProcessed(oooTemp);
|
||||
|
||||
Assert.False(actual);
|
||||
}
|
||||
}
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -1,880 +0,0 @@
|
||||
{
|
||||
"runtimeTarget": {
|
||||
"name": ".NETCoreApp,Version=v8.0",
|
||||
"signature": ""
|
||||
},
|
||||
"compilationOptions": {},
|
||||
"targets": {
|
||||
".NETCoreApp,Version=v8.0": {
|
||||
"FabApprovalWorkerService/1.0.0": {
|
||||
"dependencies": {
|
||||
"CsvHelper": "31.0.0",
|
||||
"Dapper": "2.1.28",
|
||||
"Dapper.Contrib": "2.0.78",
|
||||
"Microsoft.Extensions.Hosting": "8.0.0",
|
||||
"NLog": "5.2.8",
|
||||
"NLog.Extensions.Logging": "5.3.8",
|
||||
"System.Data.SqlClient": "4.8.6"
|
||||
},
|
||||
"runtime": {
|
||||
"FabApprovalWorkerService.dll": {}
|
||||
}
|
||||
},
|
||||
"CsvHelper/31.0.0": {
|
||||
"dependencies": {
|
||||
"System.Linq.Async": "4.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/CsvHelper.dll": {
|
||||
"assemblyVersion": "31.0.0.0",
|
||||
"fileVersion": "31.0.0.12"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Dapper/2.1.28": {
|
||||
"runtime": {
|
||||
"lib/net7.0/Dapper.dll": {
|
||||
"assemblyVersion": "2.0.0.0",
|
||||
"fileVersion": "2.1.28.55233"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Dapper.Contrib/2.0.78": {
|
||||
"dependencies": {
|
||||
"Dapper": "2.1.28"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net5.0/Dapper.Contrib.dll": {
|
||||
"assemblyVersion": "2.0.0.0",
|
||||
"fileVersion": "2.0.78.45418"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Configuration/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.Configuration.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Primitives": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Configuration.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Configuration.Abstractions/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.Primitives": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Configuration.Abstractions.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Configuration.Binder/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.Configuration.Abstractions": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Configuration.Binder.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Configuration.CommandLine/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.Configuration": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.Abstractions": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Configuration.CommandLine.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Configuration.EnvironmentVariables/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.Configuration": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.Abstractions": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Configuration.EnvironmentVariables.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Configuration.FileExtensions/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.Configuration": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.FileProviders.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.FileProviders.Physical": "8.0.0",
|
||||
"Microsoft.Extensions.Primitives": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Configuration.FileExtensions.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Configuration.Json/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.Configuration": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.FileExtensions": "8.0.0",
|
||||
"Microsoft.Extensions.FileProviders.Abstractions": "8.0.0",
|
||||
"System.Text.Json": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Configuration.Json.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Configuration.UserSecrets/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.Configuration.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.Json": "8.0.0",
|
||||
"Microsoft.Extensions.FileProviders.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.FileProviders.Physical": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Configuration.UserSecrets.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.DependencyInjection/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.DependencyInjection.Abstractions": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.DependencyInjection.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.DependencyInjection.Abstractions/8.0.0": {
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.DependencyInjection.Abstractions.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Diagnostics/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.Configuration": "8.0.0",
|
||||
"Microsoft.Extensions.Diagnostics.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Options.ConfigurationExtensions": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Diagnostics.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Diagnostics.Abstractions/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.DependencyInjection.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Options": "8.0.0",
|
||||
"System.Diagnostics.DiagnosticSource": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Diagnostics.Abstractions.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.FileProviders.Abstractions/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.Primitives": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.FileProviders.Abstractions.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.FileProviders.Physical/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.FileProviders.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.FileSystemGlobbing": "8.0.0",
|
||||
"Microsoft.Extensions.Primitives": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.FileProviders.Physical.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.FileSystemGlobbing/8.0.0": {
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.FileSystemGlobbing.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Hosting/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.Configuration": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.Binder": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.CommandLine": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.EnvironmentVariables": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.FileExtensions": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.Json": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.UserSecrets": "8.0.0",
|
||||
"Microsoft.Extensions.DependencyInjection": "8.0.0",
|
||||
"Microsoft.Extensions.DependencyInjection.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Diagnostics": "8.0.0",
|
||||
"Microsoft.Extensions.FileProviders.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.FileProviders.Physical": "8.0.0",
|
||||
"Microsoft.Extensions.Hosting.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Logging": "8.0.0",
|
||||
"Microsoft.Extensions.Logging.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Logging.Configuration": "8.0.0",
|
||||
"Microsoft.Extensions.Logging.Console": "8.0.0",
|
||||
"Microsoft.Extensions.Logging.Debug": "8.0.0",
|
||||
"Microsoft.Extensions.Logging.EventLog": "8.0.0",
|
||||
"Microsoft.Extensions.Logging.EventSource": "8.0.0",
|
||||
"Microsoft.Extensions.Options": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Hosting.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Hosting.Abstractions/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.Configuration.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.DependencyInjection.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Diagnostics.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.FileProviders.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Logging.Abstractions": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Hosting.Abstractions.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Logging/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.DependencyInjection": "8.0.0",
|
||||
"Microsoft.Extensions.Logging.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Options": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Logging.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Logging.Abstractions/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.DependencyInjection.Abstractions": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Logging.Abstractions.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Logging.Configuration/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.Configuration": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.Binder": "8.0.0",
|
||||
"Microsoft.Extensions.DependencyInjection.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Logging": "8.0.0",
|
||||
"Microsoft.Extensions.Logging.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Options": "8.0.0",
|
||||
"Microsoft.Extensions.Options.ConfigurationExtensions": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Logging.Configuration.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Logging.Console/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.DependencyInjection.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Logging": "8.0.0",
|
||||
"Microsoft.Extensions.Logging.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Logging.Configuration": "8.0.0",
|
||||
"Microsoft.Extensions.Options": "8.0.0",
|
||||
"System.Text.Json": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Logging.Console.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Logging.Debug/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.DependencyInjection.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Logging": "8.0.0",
|
||||
"Microsoft.Extensions.Logging.Abstractions": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Logging.Debug.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Logging.EventLog/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.DependencyInjection.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Logging": "8.0.0",
|
||||
"Microsoft.Extensions.Logging.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Options": "8.0.0",
|
||||
"System.Diagnostics.EventLog": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Logging.EventLog.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Logging.EventSource/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.DependencyInjection.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Logging": "8.0.0",
|
||||
"Microsoft.Extensions.Logging.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Options": "8.0.0",
|
||||
"Microsoft.Extensions.Primitives": "8.0.0",
|
||||
"System.Text.Json": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Logging.EventSource.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Options/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.DependencyInjection.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Primitives": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Options.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Options.ConfigurationExtensions/8.0.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.Configuration.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Configuration.Binder": "8.0.0",
|
||||
"Microsoft.Extensions.DependencyInjection.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Options": "8.0.0",
|
||||
"Microsoft.Extensions.Primitives": "8.0.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Options.ConfigurationExtensions.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.Extensions.Primitives/8.0.0": {
|
||||
"runtime": {
|
||||
"lib/net8.0/Microsoft.Extensions.Primitives.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"Microsoft.NETCore.Platforms/3.1.0": {},
|
||||
"Microsoft.Win32.Registry/4.7.0": {
|
||||
"dependencies": {
|
||||
"System.Security.AccessControl": "4.7.0",
|
||||
"System.Security.Principal.Windows": "4.7.0"
|
||||
}
|
||||
},
|
||||
"NLog/5.2.8": {
|
||||
"runtime": {
|
||||
"lib/netstandard2.0/NLog.dll": {
|
||||
"assemblyVersion": "5.0.0.0",
|
||||
"fileVersion": "5.2.8.2366"
|
||||
}
|
||||
}
|
||||
},
|
||||
"NLog.Extensions.Logging/5.3.8": {
|
||||
"dependencies": {
|
||||
"Microsoft.Extensions.Configuration.Abstractions": "8.0.0",
|
||||
"Microsoft.Extensions.Logging": "8.0.0",
|
||||
"NLog": "5.2.8"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/net8.0/NLog.Extensions.Logging.dll": {
|
||||
"assemblyVersion": "5.0.0.0",
|
||||
"fileVersion": "5.3.8.469"
|
||||
}
|
||||
}
|
||||
},
|
||||
"runtime.native.System.Data.SqlClient.sni/4.7.0": {
|
||||
"dependencies": {
|
||||
"runtime.win-arm64.runtime.native.System.Data.SqlClient.sni": "4.4.0",
|
||||
"runtime.win-x64.runtime.native.System.Data.SqlClient.sni": "4.4.0",
|
||||
"runtime.win-x86.runtime.native.System.Data.SqlClient.sni": "4.4.0"
|
||||
}
|
||||
},
|
||||
"runtime.win-arm64.runtime.native.System.Data.SqlClient.sni/4.4.0": {
|
||||
"runtimeTargets": {
|
||||
"runtimes/win-arm64/native/sni.dll": {
|
||||
"rid": "win-arm64",
|
||||
"assetType": "native",
|
||||
"fileVersion": "4.6.25512.1"
|
||||
}
|
||||
}
|
||||
},
|
||||
"runtime.win-x64.runtime.native.System.Data.SqlClient.sni/4.4.0": {
|
||||
"runtimeTargets": {
|
||||
"runtimes/win-x64/native/sni.dll": {
|
||||
"rid": "win-x64",
|
||||
"assetType": "native",
|
||||
"fileVersion": "4.6.25512.1"
|
||||
}
|
||||
}
|
||||
},
|
||||
"runtime.win-x86.runtime.native.System.Data.SqlClient.sni/4.4.0": {
|
||||
"runtimeTargets": {
|
||||
"runtimes/win-x86/native/sni.dll": {
|
||||
"rid": "win-x86",
|
||||
"assetType": "native",
|
||||
"fileVersion": "4.6.25512.1"
|
||||
}
|
||||
}
|
||||
},
|
||||
"System.Data.SqlClient/4.8.6": {
|
||||
"dependencies": {
|
||||
"Microsoft.Win32.Registry": "4.7.0",
|
||||
"System.Security.Principal.Windows": "4.7.0",
|
||||
"runtime.native.System.Data.SqlClient.sni": "4.7.0"
|
||||
},
|
||||
"runtime": {
|
||||
"lib/netcoreapp2.1/System.Data.SqlClient.dll": {
|
||||
"assemblyVersion": "4.6.1.6",
|
||||
"fileVersion": "4.700.23.52603"
|
||||
}
|
||||
},
|
||||
"runtimeTargets": {
|
||||
"runtimes/unix/lib/netcoreapp2.1/System.Data.SqlClient.dll": {
|
||||
"rid": "unix",
|
||||
"assetType": "runtime",
|
||||
"assemblyVersion": "4.6.1.6",
|
||||
"fileVersion": "4.700.23.52603"
|
||||
},
|
||||
"runtimes/win/lib/netcoreapp2.1/System.Data.SqlClient.dll": {
|
||||
"rid": "win",
|
||||
"assetType": "runtime",
|
||||
"assemblyVersion": "4.6.1.6",
|
||||
"fileVersion": "4.700.23.52603"
|
||||
}
|
||||
}
|
||||
},
|
||||
"System.Diagnostics.DiagnosticSource/8.0.0": {},
|
||||
"System.Diagnostics.EventLog/8.0.0": {
|
||||
"runtime": {
|
||||
"lib/net8.0/System.Diagnostics.EventLog.dll": {
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
},
|
||||
"runtimeTargets": {
|
||||
"runtimes/win/lib/net8.0/System.Diagnostics.EventLog.Messages.dll": {
|
||||
"rid": "win",
|
||||
"assetType": "runtime",
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "0.0.0.0"
|
||||
},
|
||||
"runtimes/win/lib/net8.0/System.Diagnostics.EventLog.dll": {
|
||||
"rid": "win",
|
||||
"assetType": "runtime",
|
||||
"assemblyVersion": "8.0.0.0",
|
||||
"fileVersion": "8.0.23.53103"
|
||||
}
|
||||
}
|
||||
},
|
||||
"System.Linq.Async/4.0.0": {
|
||||
"runtime": {
|
||||
"lib/netcoreapp3.0/System.Linq.Async.dll": {
|
||||
"assemblyVersion": "4.0.0.0",
|
||||
"fileVersion": "4.0.0.2"
|
||||
}
|
||||
}
|
||||
},
|
||||
"System.Security.AccessControl/4.7.0": {
|
||||
"dependencies": {
|
||||
"Microsoft.NETCore.Platforms": "3.1.0",
|
||||
"System.Security.Principal.Windows": "4.7.0"
|
||||
}
|
||||
},
|
||||
"System.Security.Principal.Windows/4.7.0": {},
|
||||
"System.Text.Encodings.Web/8.0.0": {},
|
||||
"System.Text.Json/8.0.0": {
|
||||
"dependencies": {
|
||||
"System.Text.Encodings.Web": "8.0.0"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"libraries": {
|
||||
"FabApprovalWorkerService/1.0.0": {
|
||||
"type": "project",
|
||||
"serviceable": false,
|
||||
"sha512": ""
|
||||
},
|
||||
"CsvHelper/31.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-PypRJq7AugnCJjq6Zu5EqFDTfRv7Gh+MtSH2T/kwiGmg1UHAflq4cE8j3uMkvXSxaayVtcwi+8hC0w+30YzzWA==",
|
||||
"path": "csvhelper/31.0.0",
|
||||
"hashPath": "csvhelper.31.0.0.nupkg.sha512"
|
||||
},
|
||||
"Dapper/2.1.28": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-ha49pzOEDmCPkMxwfPSR/wxa/6RD3r42TESIgpzpi7FXq/gNVUuJVEO+wtUzntNRhtmq3BKCl0s0aAlSZLkBUA==",
|
||||
"path": "dapper/2.1.28",
|
||||
"hashPath": "dapper.2.1.28.nupkg.sha512"
|
||||
},
|
||||
"Dapper.Contrib/2.0.78": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-sUfDVIf8LlHNiz3MfUFodeyRiemfN1JFkPxYjCxFWlwNPg1iQ49mB+0E89TkywWs4X8fiRWOVDQgtH5FtzK5Kw==",
|
||||
"path": "dapper.contrib/2.0.78",
|
||||
"hashPath": "dapper.contrib.2.0.78.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Configuration/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-0J/9YNXTMWSZP2p2+nvl8p71zpSwokZXZuJW+VjdErkegAnFdO1XlqtA62SJtgVYHdKu3uPxJHcMR/r35HwFBA==",
|
||||
"path": "microsoft.extensions.configuration/8.0.0",
|
||||
"hashPath": "microsoft.extensions.configuration.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Configuration.Abstractions/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-3lE/iLSutpgX1CC0NOW70FJoGARRHbyKmG7dc0klnUZ9Dd9hS6N/POPWhKhMLCEuNN5nXEY5agmlFtH562vqhQ==",
|
||||
"path": "microsoft.extensions.configuration.abstractions/8.0.0",
|
||||
"hashPath": "microsoft.extensions.configuration.abstractions.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Configuration.Binder/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-mBMoXLsr5s1y2zOHWmKsE9veDcx8h1x/c3rz4baEdQKTeDcmQAPNbB54Pi/lhFO3K431eEq6PFbMgLaa6PHFfA==",
|
||||
"path": "microsoft.extensions.configuration.binder/8.0.0",
|
||||
"hashPath": "microsoft.extensions.configuration.binder.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Configuration.CommandLine/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-NZuZMz3Q8Z780nKX3ifV1fE7lS+6pynDHK71OfU4OZ1ItgvDOhyOC7E6z+JMZrAj63zRpwbdldYFk499t3+1dQ==",
|
||||
"path": "microsoft.extensions.configuration.commandline/8.0.0",
|
||||
"hashPath": "microsoft.extensions.configuration.commandline.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Configuration.EnvironmentVariables/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-plvZ0ZIpq+97gdPNNvhwvrEZ92kNml9hd1pe3idMA7svR0PztdzVLkoWLcRFgySYXUJc3kSM3Xw3mNFMo/bxRA==",
|
||||
"path": "microsoft.extensions.configuration.environmentvariables/8.0.0",
|
||||
"hashPath": "microsoft.extensions.configuration.environmentvariables.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Configuration.FileExtensions/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-McP+Lz/EKwvtCv48z0YImw+L1gi1gy5rHhNaNIY2CrjloV+XY8gydT8DjMR6zWeL13AFK+DioVpppwAuO1Gi1w==",
|
||||
"path": "microsoft.extensions.configuration.fileextensions/8.0.0",
|
||||
"hashPath": "microsoft.extensions.configuration.fileextensions.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Configuration.Json/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-C2wqUoh9OmRL1akaCcKSTmRU8z0kckfImG7zLNI8uyi47Lp+zd5LWAD17waPQEqCz3ioWOCrFUo+JJuoeZLOBw==",
|
||||
"path": "microsoft.extensions.configuration.json/8.0.0",
|
||||
"hashPath": "microsoft.extensions.configuration.json.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Configuration.UserSecrets/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-ihDHu2dJYQird9pl2CbdwuNDfvCZdOS0S7SPlNfhPt0B81UTT+yyZKz2pimFZGUp3AfuBRnqUCxB2SjsZKHVUw==",
|
||||
"path": "microsoft.extensions.configuration.usersecrets/8.0.0",
|
||||
"hashPath": "microsoft.extensions.configuration.usersecrets.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.DependencyInjection/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-V8S3bsm50ig6JSyrbcJJ8bW2b9QLGouz+G1miK3UTaOWmMtFwNNNzUf4AleyDWUmTrWMLNnFSLEQtxmxgNQnNQ==",
|
||||
"path": "microsoft.extensions.dependencyinjection/8.0.0",
|
||||
"hashPath": "microsoft.extensions.dependencyinjection.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.DependencyInjection.Abstractions/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-cjWrLkJXK0rs4zofsK4bSdg+jhDLTaxrkXu4gS6Y7MAlCvRyNNgwY/lJi5RDlQOnSZweHqoyvgvbdvQsRIW+hg==",
|
||||
"path": "microsoft.extensions.dependencyinjection.abstractions/8.0.0",
|
||||
"hashPath": "microsoft.extensions.dependencyinjection.abstractions.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Diagnostics/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-3PZp/YSkIXrF7QK7PfC1bkyRYwqOHpWFad8Qx+4wkuumAeXo1NHaxpS9LboNA9OvNSAu+QOVlXbMyoY+pHSqcw==",
|
||||
"path": "microsoft.extensions.diagnostics/8.0.0",
|
||||
"hashPath": "microsoft.extensions.diagnostics.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Diagnostics.Abstractions/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-JHYCQG7HmugNYUhOl368g+NMxYE/N/AiclCYRNlgCY9eVyiBkOHMwK4x60RYMxv9EL3+rmj1mqHvdCiPpC+D4Q==",
|
||||
"path": "microsoft.extensions.diagnostics.abstractions/8.0.0",
|
||||
"hashPath": "microsoft.extensions.diagnostics.abstractions.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.FileProviders.Abstractions/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-ZbaMlhJlpisjuWbvXr4LdAst/1XxH3vZ6A0BsgTphZ2L4PGuxRLz7Jr/S7mkAAnOn78Vu0fKhEgNF5JO3zfjqQ==",
|
||||
"path": "microsoft.extensions.fileproviders.abstractions/8.0.0",
|
||||
"hashPath": "microsoft.extensions.fileproviders.abstractions.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.FileProviders.Physical/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-UboiXxpPUpwulHvIAVE36Knq0VSHaAmfrFkegLyBZeaADuKezJ/AIXYAW8F5GBlGk/VaibN2k/Zn1ca8YAfVdA==",
|
||||
"path": "microsoft.extensions.fileproviders.physical/8.0.0",
|
||||
"hashPath": "microsoft.extensions.fileproviders.physical.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.FileSystemGlobbing/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-OK+670i7esqlQrPjdIKRbsyMCe9g5kSLpRRQGSr4Q58AOYEe/hCnfLZprh7viNisSUUQZmMrbbuDaIrP+V1ebQ==",
|
||||
"path": "microsoft.extensions.filesystemglobbing/8.0.0",
|
||||
"hashPath": "microsoft.extensions.filesystemglobbing.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Hosting/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-ItYHpdqVp5/oFLT5QqbopnkKlyFG9EW/9nhM6/yfObeKt6Su0wkBio6AizgRHGNwhJuAtlE5VIjow5JOTrip6w==",
|
||||
"path": "microsoft.extensions.hosting/8.0.0",
|
||||
"hashPath": "microsoft.extensions.hosting.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Hosting.Abstractions/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-AG7HWwVRdCHlaA++1oKDxLsXIBxmDpMPb3VoyOoAghEWnkUvEAdYQUwnV4jJbAaa/nMYNiEh5ByoLauZBEiovg==",
|
||||
"path": "microsoft.extensions.hosting.abstractions/8.0.0",
|
||||
"hashPath": "microsoft.extensions.hosting.abstractions.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Logging/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-tvRkov9tAJ3xP51LCv3FJ2zINmv1P8Hi8lhhtcKGqM+ImiTCC84uOPEI4z8Cdq2C3o9e+Aa0Gw0rmrsJD77W+w==",
|
||||
"path": "microsoft.extensions.logging/8.0.0",
|
||||
"hashPath": "microsoft.extensions.logging.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Logging.Abstractions/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-arDBqTgFCyS0EvRV7O3MZturChstm50OJ0y9bDJvAcmEPJm0FFpFyjU/JLYyStNGGey081DvnQYlncNX5SJJGA==",
|
||||
"path": "microsoft.extensions.logging.abstractions/8.0.0",
|
||||
"hashPath": "microsoft.extensions.logging.abstractions.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Logging.Configuration/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-ixXXV0G/12g6MXK65TLngYN9V5hQQRuV+fZi882WIoVJT7h5JvoYoxTEwCgdqwLjSneqh1O+66gM8sMr9z/rsQ==",
|
||||
"path": "microsoft.extensions.logging.configuration/8.0.0",
|
||||
"hashPath": "microsoft.extensions.logging.configuration.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Logging.Console/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-e+48o7DztoYog+PY430lPxrM4mm3PbA6qucvQtUDDwVo4MO+ejMw7YGc/o2rnxbxj4isPxdfKFzTxvXMwAz83A==",
|
||||
"path": "microsoft.extensions.logging.console/8.0.0",
|
||||
"hashPath": "microsoft.extensions.logging.console.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Logging.Debug/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-dt0x21qBdudHLW/bjMJpkixv858RRr8eSomgVbU8qljOyfrfDGi1JQvpF9w8S7ziRPtRKisuWaOwFxJM82GxeA==",
|
||||
"path": "microsoft.extensions.logging.debug/8.0.0",
|
||||
"hashPath": "microsoft.extensions.logging.debug.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Logging.EventLog/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-3X9D3sl7EmOu7vQp5MJrmIJBl5XSdOhZPYXUeFfYa6Nnm9+tok8x3t3IVPLhm7UJtPOU61ohFchw8rNm9tIYOQ==",
|
||||
"path": "microsoft.extensions.logging.eventlog/8.0.0",
|
||||
"hashPath": "microsoft.extensions.logging.eventlog.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Logging.EventSource/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-oKcPMrw+luz2DUAKhwFXrmFikZWnyc8l2RKoQwqU3KIZZjcfoJE0zRHAnqATfhRZhtcbjl/QkiY2Xjxp0xu+6w==",
|
||||
"path": "microsoft.extensions.logging.eventsource/8.0.0",
|
||||
"hashPath": "microsoft.extensions.logging.eventsource.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Options/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-JOVOfqpnqlVLUzINQ2fox8evY2SKLYJ3BV8QDe/Jyp21u1T7r45x/R/5QdteURMR5r01GxeJSBBUOCOyaNXA3g==",
|
||||
"path": "microsoft.extensions.options/8.0.0",
|
||||
"hashPath": "microsoft.extensions.options.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Options.ConfigurationExtensions/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-0f4DMRqEd50zQh+UyJc+/HiBsZ3vhAQALgdkcQEalSH1L2isdC7Yj54M3cyo5e+BeO5fcBQ7Dxly8XiBBcvRgw==",
|
||||
"path": "microsoft.extensions.options.configurationextensions/8.0.0",
|
||||
"hashPath": "microsoft.extensions.options.configurationextensions.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Extensions.Primitives/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-bXJEZrW9ny8vjMF1JV253WeLhpEVzFo1lyaZu1vQ4ZxWUlVvknZ/+ftFgVheLubb4eZPSwwxBeqS1JkCOjxd8g==",
|
||||
"path": "microsoft.extensions.primitives/8.0.0",
|
||||
"hashPath": "microsoft.extensions.primitives.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.NETCore.Platforms/3.1.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-z7aeg8oHln2CuNulfhiLYxCVMPEwBl3rzicjvIX+4sUuCwvXw5oXQEtbiU2c0z4qYL5L3Kmx0mMA/+t/SbY67w==",
|
||||
"path": "microsoft.netcore.platforms/3.1.0",
|
||||
"hashPath": "microsoft.netcore.platforms.3.1.0.nupkg.sha512"
|
||||
},
|
||||
"Microsoft.Win32.Registry/4.7.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-KSrRMb5vNi0CWSGG1++id2ZOs/1QhRqROt+qgbEAdQuGjGrFcl4AOl4/exGPUYz2wUnU42nvJqon1T3U0kPXLA==",
|
||||
"path": "microsoft.win32.registry/4.7.0",
|
||||
"hashPath": "microsoft.win32.registry.4.7.0.nupkg.sha512"
|
||||
},
|
||||
"NLog/5.2.8": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-jAIELkWBs1CXFPp986KSGpDFQZHCFccO+LMbKBTTNm42KifaI1mYzFMFQQfuGmGMTrCx0TFPhDjHDE4cLAZWiQ==",
|
||||
"path": "nlog/5.2.8",
|
||||
"hashPath": "nlog.5.2.8.nupkg.sha512"
|
||||
},
|
||||
"NLog.Extensions.Logging/5.3.8": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-6VD0lyeokWltL6j8lO7mS7v7lbuO/qn0F7kdvhKhEx1JvFyD39nzohOK3JvkVh4Nn3mrcMDCyDxvTvmiW55jQg==",
|
||||
"path": "nlog.extensions.logging/5.3.8",
|
||||
"hashPath": "nlog.extensions.logging.5.3.8.nupkg.sha512"
|
||||
},
|
||||
"runtime.native.System.Data.SqlClient.sni/4.7.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-9kyFSIdN3T0qjDQ2R0HRXYIhS3l5psBzQi6qqhdLz+SzFyEy4sVxNOke+yyYv8Cu8rPER12c3RDjLT8wF3WBYQ==",
|
||||
"path": "runtime.native.system.data.sqlclient.sni/4.7.0",
|
||||
"hashPath": "runtime.native.system.data.sqlclient.sni.4.7.0.nupkg.sha512"
|
||||
},
|
||||
"runtime.win-arm64.runtime.native.System.Data.SqlClient.sni/4.4.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-LbrynESTp3bm5O/+jGL8v0Qg5SJlTV08lpIpFesXjF6uGNMWqFnUQbYBJwZTeua6E/Y7FIM1C54Ey1btLWupdg==",
|
||||
"path": "runtime.win-arm64.runtime.native.system.data.sqlclient.sni/4.4.0",
|
||||
"hashPath": "runtime.win-arm64.runtime.native.system.data.sqlclient.sni.4.4.0.nupkg.sha512"
|
||||
},
|
||||
"runtime.win-x64.runtime.native.System.Data.SqlClient.sni/4.4.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-38ugOfkYJqJoX9g6EYRlZB5U2ZJH51UP8ptxZgdpS07FgOEToV+lS11ouNK2PM12Pr6X/PpT5jK82G3DwH/SxQ==",
|
||||
"path": "runtime.win-x64.runtime.native.system.data.sqlclient.sni/4.4.0",
|
||||
"hashPath": "runtime.win-x64.runtime.native.system.data.sqlclient.sni.4.4.0.nupkg.sha512"
|
||||
},
|
||||
"runtime.win-x86.runtime.native.System.Data.SqlClient.sni/4.4.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-YhEdSQUsTx+C8m8Bw7ar5/VesXvCFMItyZF7G1AUY+OM0VPZUOeAVpJ4Wl6fydBGUYZxojTDR3I6Bj/+BPkJNA==",
|
||||
"path": "runtime.win-x86.runtime.native.system.data.sqlclient.sni/4.4.0",
|
||||
"hashPath": "runtime.win-x86.runtime.native.system.data.sqlclient.sni.4.4.0.nupkg.sha512"
|
||||
},
|
||||
"System.Data.SqlClient/4.8.6": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-2Ij/LCaTQRyAi5lAv7UUTV9R2FobC8xN9mE0fXBZohum/xLl8IZVmE98Rq5ugQHjCgTBRKqpXRb4ORulRdA6Ig==",
|
||||
"path": "system.data.sqlclient/4.8.6",
|
||||
"hashPath": "system.data.sqlclient.4.8.6.nupkg.sha512"
|
||||
},
|
||||
"System.Diagnostics.DiagnosticSource/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-c9xLpVz6PL9lp/djOWtk5KPDZq3cSYpmXoJQY524EOtuFl5z9ZtsotpsyrDW40U1DRnQSYvcPKEUV0X//u6gkQ==",
|
||||
"path": "system.diagnostics.diagnosticsource/8.0.0",
|
||||
"hashPath": "system.diagnostics.diagnosticsource.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"System.Diagnostics.EventLog/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-fdYxcRjQqTTacKId/2IECojlDSFvp7LP5N78+0z/xH7v/Tuw5ZAxu23Y6PTCRinqyu2ePx+Gn1098NC6jM6d+A==",
|
||||
"path": "system.diagnostics.eventlog/8.0.0",
|
||||
"hashPath": "system.diagnostics.eventlog.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"System.Linq.Async/4.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-WbiYEedFZeM+psmMyoCt1AKbZppAZg8Eq1ZTQ+521fGNeXqlgJj0tZYV5n1LsKRO5osQuitYxGNuzPTy3213sg==",
|
||||
"path": "system.linq.async/4.0.0",
|
||||
"hashPath": "system.linq.async.4.0.0.nupkg.sha512"
|
||||
},
|
||||
"System.Security.AccessControl/4.7.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-JECvTt5aFF3WT3gHpfofL2MNNP6v84sxtXxpqhLBCcDRzqsPBmHhQ6shv4DwwN2tRlzsUxtb3G9M3763rbXKDg==",
|
||||
"path": "system.security.accesscontrol/4.7.0",
|
||||
"hashPath": "system.security.accesscontrol.4.7.0.nupkg.sha512"
|
||||
},
|
||||
"System.Security.Principal.Windows/4.7.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-ojD0PX0XhneCsUbAZVKdb7h/70vyYMDYs85lwEI+LngEONe/17A0cFaRFqZU+sOEidcVswYWikYOQ9PPfjlbtQ==",
|
||||
"path": "system.security.principal.windows/4.7.0",
|
||||
"hashPath": "system.security.principal.windows.4.7.0.nupkg.sha512"
|
||||
},
|
||||
"System.Text.Encodings.Web/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-yev/k9GHAEGx2Rg3/tU6MQh4HGBXJs70y7j1LaM1i/ER9po+6nnQ6RRqTJn1E7Xu0fbIFK80Nh5EoODxrbxwBQ==",
|
||||
"path": "system.text.encodings.web/8.0.0",
|
||||
"hashPath": "system.text.encodings.web.8.0.0.nupkg.sha512"
|
||||
},
|
||||
"System.Text.Json/8.0.0": {
|
||||
"type": "package",
|
||||
"serviceable": true,
|
||||
"sha512": "sha512-OdrZO2WjkiEG6ajEFRABTRCi/wuXQPxeV6g8xvUJqdxMvvuCCEk86zPla8UiIQJz3durtUEbNyY/3lIhS0yZvQ==",
|
||||
"path": "system.text.json/8.0.0",
|
||||
"hashPath": "system.text.json.8.0.0.nupkg.sha512"
|
||||
}
|
||||
}
|
||||
}
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -1,13 +0,0 @@
|
||||
{
|
||||
"runtimeOptions": {
|
||||
"tfm": "net8.0",
|
||||
"framework": {
|
||||
"name": "Microsoft.NETCore.App",
|
||||
"version": "8.0.0"
|
||||
},
|
||||
"configProperties": {
|
||||
"System.GC.Server": true,
|
||||
"System.Runtime.Serialization.EnableUnsafeBinaryFormatterSerialization": false
|
||||
}
|
||||
}
|
||||
}
|
File diff suppressed because it is too large
Load Diff
Binary file not shown.
Binary file not shown.
@ -1,12 +0,0 @@
|
||||
{
|
||||
"runtimeOptions": {
|
||||
"tfm": "net8.0",
|
||||
"framework": {
|
||||
"name": "Microsoft.NETCore.App",
|
||||
"version": "8.0.0"
|
||||
},
|
||||
"configProperties": {
|
||||
"System.Runtime.Serialization.EnableUnsafeBinaryFormatterSerialization": false
|
||||
}
|
||||
}
|
||||
}
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -1,11 +0,0 @@
|
||||
{
|
||||
"Logging": {
|
||||
"LogLevel": {
|
||||
"Default": "Information",
|
||||
"Microsoft.Hosting.Lifetime": "Information"
|
||||
}
|
||||
},
|
||||
"ConnectionStrings": {
|
||||
"Default": "Data Source=MESTSV02EC.infineon.com\\TEST1,50572;Integrated Security=False;Initial Catalog=FabApprovalSystem;User ID=fab_approval_admin_test;Password=Fab_approval_admin_test2023!;Connect Timeout=15;Encrypt=False;TrustServerCertificate=False; Min Pool Size=15"
|
||||
}
|
||||
}
|
@ -1,8 +0,0 @@
|
||||
{
|
||||
"Logging": {
|
||||
"LogLevel": {
|
||||
"Default": "Information",
|
||||
"Microsoft.Hosting.Lifetime": "Information"
|
||||
}
|
||||
}
|
||||
}
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user