mirror of
https://github.com/mxpv/podsync.git
synced 2024-05-11 05:55:04 +00:00
Implement redis storage
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Podsync.Services.Storage;
|
||||
|
||||
namespace Podsync.Controllers
|
||||
{
|
||||
public class StatusController : Controller
|
||||
{
|
||||
private readonly IStorageService _storageService;
|
||||
|
||||
public StatusController(IStorageService storageService)
|
||||
{
|
||||
_storageService = storageService;
|
||||
}
|
||||
|
||||
public async Task<string> Index()
|
||||
{
|
||||
var time = await _storageService.Ping();
|
||||
|
||||
return $"Path: {Request.Path}\r\n" +
|
||||
$"Redis: {time}";
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user