Merge pull request #366 from hchen2020/master
GetAgent perInstanceCache
This commit is contained in:
commit
22b82b9a69
|
|
@ -1,5 +1,3 @@
|
|||
using BotSharp.Abstraction.Agents.Models;
|
||||
using BotSharp.Abstraction.Repositories.Filters;
|
||||
using BotSharp.Abstraction.Routing.Settings;
|
||||
|
||||
namespace BotSharp.Core.Agents.Services;
|
||||
|
|
@ -7,7 +5,7 @@ namespace BotSharp.Core.Agents.Services;
|
|||
public partial class AgentService
|
||||
{
|
||||
#if !DEBUG
|
||||
[MemoryCache(10 * 60)]
|
||||
[MemoryCache(10 * 60, perInstanceCache: true)]
|
||||
#endif
|
||||
public async Task<PagedItems<Agent>> GetAgents(AgentFilter filter)
|
||||
{
|
||||
|
|
@ -29,7 +27,7 @@ public partial class AgentService
|
|||
}
|
||||
|
||||
#if !DEBUG
|
||||
[MemoryCache(10 * 60)]
|
||||
[MemoryCache(10 * 60, perInstanceCache: true)]
|
||||
#endif
|
||||
public async Task<Agent> GetAgent(string id)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in a new issue