实体框架、自跟踪实体和sqlserver文件流

发布于 2024-11-19 17:50:13 字数 187 浏览 8 评论 0原文

我刚刚启动一个项目,需要有一个读取和写入文件的 WCF 服务。

该架构基于使用实体框架自我跟踪实体的 DDD。

简单的 GUI 应该显示一个包含文件列表的网格,然后单击可以下载它的行。

我可以在此架构中使用文件流 sql server 2008 功能吗?哪种策略是管理此类实体的最佳策略?

谢谢。

I just start a project where I need to have a WCF services that read and write files.

The architecture is based on DDD using Entity Framework Self-Tracking Entity.

The simple GUI should show a grid with a list of file and then click the row you can download it.

Can I use the file stream sql server 2008 feature with this architecture? Which strategy is the best one to manage this kind of entity?

Thanks.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

夜唯美灬不弃 2024-11-26 17:50:13

使用 EF 时,Filestream 不会为您提供帮助。 EF 不使用流功能,它将其加载为 varbinary(max)。如果您想利用文件流,则必须 直接使用 ADO.NET 从数据库加载它 并且您需要一个 流媒体服务以有效的方式将其传回客户端。

Filestream will not help you when using EF. EF doesn't use streaming feature, it loads it as varbinary(max). If you wan to take advantage of filestream you must load it from database with ADO.NET directly and you need a streaming service to pass it back to the client in efficient way.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文