小编san*_*ovm的帖子

嵌入模式下不支持RavenDB IsOperationAllowedOnDocument

使用嵌入模式调用InvalidOperationExceptionIsOperationAllowedOnDocument会抛出RavenDB .

我可以在IsOperationAllowedOnDocument实现中看到一个子句检查嵌入模式下的调用.

namespace Raven.Client.Authorization
{
    public static class AuthorizationClientExtensions
    {
        public static OperationAllowedResult[] IsOperationAllowedOnDocument(this ISyncAdvancedSessionOperation session, string userId, string operation, params string[] documentIds)
        {
            var serverClient = session.DatabaseCommands as ServerClient;
            if (serverClient == null)
                throw new InvalidOperationException("Cannot get whatever operation is allowed on document in embedded mode.");
Run Code Online (Sandbox Code Playgroud)

除了不使用嵌入模式之外,还有其他解决方法吗?

谢谢你的时间.

ravendb

5
推荐指数
1
解决办法
183
查看次数

标签 统计

ravendb ×1