Merge pull request #2 from anjoy8/master

test redis mq di
This commit is contained in:
胡丁文 2021-01-11 14:22:49 +08:00 committed by GitHub
commit 014c64f7b7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
12 changed files with 23 additions and 20 deletions

View File

@ -666,7 +666,7 @@
</summary>
<returns></returns>
</member>
<member name="M:Blog.Core.Controllers.ValuesController.RedisMq(Blog.Core.Common.IRedisBasketRepository)">
<member name="M:Blog.Core.Controllers.ValuesController.RedisMq(Blog.Core.Extensions.IRedisBasketRepository)">
<summary>
测试Redis消息队列
</summary>

View File

@ -1,10 +1,10 @@
using AutoMapper;
using Blog.Core.Common;
using Blog.Core.Common.HttpContextUser;
using Blog.Core.Common.HttpRestSharp;
using Blog.Core.Common.WebApiClients.HttpApis;
using Blog.Core.EventBus;
using Blog.Core.EventBus.EventHandling;
using Blog.Core.Extensions;
using Blog.Core.Filter;
using Blog.Core.IServices;
using Blog.Core.Model;

View File

@ -7,8 +7,6 @@
<ItemGroup>
<Compile Remove="LogHelper\ILoggerHelper.cs" />
<Compile Remove="LogHelper\LogHelper.cs" />
<Compile Remove="Redis\IRedisCacheManager.cs" />
<Compile Remove="Redis\RedisCacheManager.cs" />
</ItemGroup>
<ItemGroup>

View File

@ -1,4 +1,5 @@
using Blog.Core.Common;
using Blog.Core.Extensions;
using Castle.DynamicProxy;
using System;
using System.Linq;

View File

@ -3,10 +3,8 @@ using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Http;
using Microsoft.Extensions.DependencyInjection;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Reflection;
namespace Blog.Core.Extensions
{

View File

@ -3,7 +3,7 @@ using System;
using System.Collections.Generic;
using System.Threading.Tasks;
namespace Blog.Core.Common
namespace Blog.Core.Extensions
{
/// <summary>
/// Redis缓存接口

View File

@ -1,10 +1,6 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Blog.Core.Common
namespace Blog.Core.Extensions
{
/// <summary>
/// Redis缓存接口

View File

@ -1,4 +1,5 @@
using Microsoft.Extensions.Logging;
using Blog.Core.Common;
using Microsoft.Extensions.Logging;
using Newtonsoft.Json;
using StackExchange.Redis;
using System;
@ -6,7 +7,7 @@ using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
namespace Blog.Core.Common
namespace Blog.Core.Extensions
{
public class RedisBasketRepository : IRedisBasketRepository
{

View File

@ -1,7 +1,8 @@
using StackExchange.Redis;
using Blog.Core.Common;
using StackExchange.Redis;
using System;
namespace Blog.Core.Common
namespace Blog.Core.Extensions
{
public class RedisCacheManager : IRedisCacheManager
{

View File

@ -1,12 +1,20 @@
using InitQ.Abstractions;
using Blog.Core.IServices;
using InitQ.Abstractions;
using InitQ.Attributes;
using System;
using System.Threading.Tasks;
namespace Blog.Core.Common.Redis
namespace Blog.Core.Extensions.Redis
{
public class RedisSubscribe : IRedisSubscribe
{
private readonly IBlogArticleServices _blogArticleServices;
public RedisSubscribe(IBlogArticleServices blogArticleServices)
{
_blogArticleServices = blogArticleServices;
}
[Subscribe(RedisMqKey.Loging)]
private async Task SubRedisLoging(string msg)
{

View File

@ -3,7 +3,7 @@ using InitQ.Attributes;
using System;
using System.Threading.Tasks;
namespace Blog.Core.Common.Redis
namespace Blog.Core.Extensions.Redis
{
public class RedisSubscribe2 : IRedisSubscribe
{

View File

@ -1,5 +1,5 @@
using Blog.Core.Common;
using Blog.Core.Common.Redis;
using Blog.Core.Extensions.Redis;
using InitQ;
using Microsoft.Extensions.DependencyInjection;
using System;