gpt4 book ai didi

来自 AppFabric 提供程序的 Sqlite 连接

转载 作者:行者123 更新时间:2023-12-03 17:58:11 25 4
gpt4 key购买 nike

我们想在我们的项目中使用 AppFabric 缓存,并使用包括 ReadThruogh-WriteBehind 功能的 Sqlite。我成功创建了 Provider 并注册到 GAC。如果我选择 mssql 服务作为数据提供者,一切都会成功。另一方面,如果我选择 sqlite,它会在 GAC 的 Provider 上的这一行引发异常。

SQLiteConnection conn = new SQLiteConnection(@"path");

此异常来自 GAC 中的 Provider,但如果我在服务中编写此行,它可以工作。所以问题是,如果我想从 GAC 连接 sqlite,它会引发异常:

The cache provider threw an exception during read.



错误信息中没有更多解释,但是如果尝试从服务连接sqlite,则连接成功。 Sqlite db 文件允许所有人阅读。

似乎存在身份验证问题或类似问题。有什么解决办法?

最佳答案

来自 http://msdn.developer-works.com/article/12056989/.ErrorCode%26lt%3BERRCA0025%26gt%3B%3ASubStatus%26lt%3BES0001%26gt%3B

The error code that you are getting translates to DataCacheErrorCode.ReadThroughProviderFailure so this is an error which is happening on the service side and not the client side so client configuration will not help.

In this case you should first check if you have created a Read-Through provider and installed it on the Caching server.

You will get this error if you have created a CUSTOM Read-Through provider (something new in AppFabric 1.1) and an exception is happening in the READ method of that provider. More details about creating the provider at http://msdn.microsoft.com/en-us/library/hh361698(v=azure.10).aspx

If this is a reproducible error, then you should be able to easily Debug the DistributedCacheService.exe process on the Cache server and put a breakpoint on the PUT method and step through it to see if you can find the exception.

The section Testing and debugging the provider out this in detail.

关于来自 AppFabric 提供程序的 Sqlite 连接,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28062529/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com