Compare commits

..

3 Commits

Author SHA1 Message Date
1d4bf2d0b6 Merge pull request 'feature/rabbit-mq' (#4) from feature/rabbit-mq into master
Some checks reported errors
continuous-integration/drone/push Build was killed
Reviewed-on: #4
2021-01-17 17:16:53 +01:00
79dcb4d75a Added RabbitMq IsConnected
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/pr Build is passing
2021-01-17 17:13:26 +01:00
7c67fa7de0 Array empty
All checks were successful
continuous-integration/drone/push Build is passing
2021-01-17 16:54:39 +01:00
2 changed files with 3 additions and 2 deletions

View File

@ -12,6 +12,7 @@ using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting; using Microsoft.Extensions.Hosting;
using Microsoft.IdentityModel.Tokens; using Microsoft.IdentityModel.Tokens;
using NSwag.Generation.Processors.Security; using NSwag.Generation.Processors.Security;
using System;
using System.Text; using System.Text;
namespace Birdmap.API namespace Birdmap.API
@ -71,7 +72,7 @@ namespace Birdmap.API
{ {
opt.Title = "Birdmap"; opt.Title = "Birdmap";
opt.OperationProcessors.Add(new OperationSecurityScopeProcessor("Jwt Token")); opt.OperationProcessors.Add(new OperationSecurityScopeProcessor("Jwt Token"));
opt.AddSecurity("Jwt Token", new string[] { }, opt.AddSecurity("Jwt Token", Array.Empty<string>(),
new NSwag.OpenApiSecurityScheme new NSwag.OpenApiSecurityScheme
{ {
Type = NSwag.OpenApiSecuritySchemeType.ApiKey, Type = NSwag.OpenApiSecuritySchemeType.ApiKey,

View File

@ -19,7 +19,7 @@ namespace Birdmap.BLL.Services.CommunationServices.RabbitMq
private readonly IConnectionFactory _factory; private readonly IConnectionFactory _factory;
private readonly RabbitMqClientOptions _options; private readonly RabbitMqClientOptions _options;
public override bool IsConnected => throw new NotImplementedException(); public override bool IsConnected => _connection.IsOpen;
public RabbitMqClientService(RabbitMqClientOptions options, ILogger<RabbitMqClientService> logger, IInputService inputService, IHubContext<DevicesHub, IDevicesHubClient> hubContext) public RabbitMqClientService(RabbitMqClientOptions options, ILogger<RabbitMqClientService> logger, IInputService inputService, IHubContext<DevicesHub, IDevicesHubClient> hubContext)
: base(logger, inputService, hubContext) : base(logger, inputService, hubContext)