创建具有外部持久性的文档库

发布于 2024-07-25 16:31:19 字数 367 浏览 12 评论 0原文

我想创建一个自定义文档库,在其中使用标准 UI,但实现不同的持久层。 基本上从不同的源系统获取和显示文档。 这样我就可以使用现有的对象模型,同时利用 SharePoint 中出色的办公集成。

我在这里找到了一篇不错的文章,但他们在作弊,他们为外在的坚持。

我已经查看了 SPList 和 SPDocumentLibrary 对象,但无法重写必要的方法。

我查看了事件框架,它更接近,但缺少“GetFile”或“PopulateList”等重要事件。

有什么想法吗?

I would like to create a custom document library where I use the standard UI but implement a different persistence layer. Basically fetch and display documents from a different source system. This way I can use my existing object model but leverage the great office integration within SharePoint.

I found a decent article here but they are cheating, they have coded a completely new UI for the external persistence.

I have looked at the SPList and SPDocumentLibrary objects but I can't override the necessary methods.

I have looked at the event framework and it is closer but it lacks important events such as 'GetFile' or 'PopulateList'.

Any thoughts?

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

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

发布评论

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

评论(4

别念他 2024-08-01 16:31:19

这对于您想要做的事情来说并不是完美的(或者甚至可能是“好的”),但我提到它主要是为了提高认识,并可能给您一些额外的想法(和警告)。

SharePoint 的存储体系结构利用两种不同的后端存储:一种用于元数据(始终是 SharePoint 的 SQL 数据库),另一种用于 BLOB 存储(默认情况下也是 SQL)。 不过,在当前形式下,SharePoint 允许您通过实现 ISPExternalBinaryProvider 接口的类型“连接”您自己的 BLOB 存储提供程序。 通过连接实现此接口的类型,您可以继续在 SQL 中存储元数据,同时将文档和其他 BLOB 项类型存储在您选择的不同存储中。

这听起来可能有点有希望,但有几个严重的考虑因素:

  1. 连接您自己的 ISPExternalBinaryProvider 会产生整个服务器场的影响。 要么全有要么全无,因此一旦连接了提供程序,所有站点和库都将使用新的提供程序。

  2. 您需要深入研究非托管代码,因为 ISPExternalBinaryProvider 要求您使用某些 IDL。

    您需要深入研究非托管

您可以在此处阅读更多信息:http://msdn.microsoft.com/en- us/library/bb802976.aspx

我的看法是,外部 BLOB 存储 (EBS) 系统此时只是一个“原型”——尚未准备好迎接黄金时段。 不过,如果不出意外的话,它也会给你一些思考的机会。 SharePoint Server 2010 希望能够利用它做更多事情,并使其更具吸引力且易于实施。

物有所值!

This isn't a perfect (or probably even a "good") fit for what you're trying to do, but I mention it primarily for awareness and to possibly give you some additional ideas (and warnings).

SharePoint's storage architecture leverages two different back-end stores: one for metadata (always SharePoint's SQL databases), and another for BLOB storage (also SQL by default). In its current form, though, SharePoint allows you to "wire-in" your own BLOB storage provider via a type that implements the ISPExternalBinaryProvider interface. Wiring in a type that implements this interface allows you to continue storing metadata in SQL while storing documents and other BLOB item types in a different store of your choice.

This probably sounds somewhat promising, but there are a couple of serious considerations:

  1. Wiring-in your own ISPExternalBinaryProvider has a farm-wide impact. It's all or nothing, so once the provider is wired in, all sites and libaries will use the new provider.

  2. You'll need to dive into unmanaged code, as the ISPExternalBinaryProvider is doing to require you to work with some IDL.

You can read more here: http://msdn.microsoft.com/en-us/library/bb802976.aspx

My take is that the external BLOB storage (EBS) system is something of a "prototype" at this point -- not ready for prime-time. If nothing else, though, it gives you something to think about. SharePoint Server 2010 will hopefully do more with it and make it more attractive and easy to implement.

For what it's worth!

无悔心 2024-08-01 16:31:19

我通过使用在创建和更新库文档时运行的持久性工作流,在表单库中实现了 SQL 持久性。

我在 Visual Studio 2008 中创建了一个 Office SharePoint 2007 工作流项目,检索 SPItem 文档内容,从 InfoPath WebForm 生成的 XML 中提取相关数据,并将其保存到数据库中。

I have implemented SQL persistence in a Form Library by using a persistence Workflow that runs on creation and update of the library's documents.

I created an Office SharePoint 2007 Workflow project in Visual Studio 2008, retrieved my SPItem document content and extracted the relevant data from the XML generated by the InfoPath WebForm and persisted it to a database.

吾家有女初长成 2024-08-01 16:31:19

如果您确实想推出自己的外部持久性,请尝试查看 TechNet 上 6 月发布的这篇全新的内容广泛的文章:

http://technet.microsoft.com/en-us/magazine/2009.06.insidesharepoint.aspx

现在,把赏金交给我。 ;)

If you really wanna roll your own external persistance, try taking a look at this brand new, extensive article from june on TechNet:

http://technet.microsoft.com/en-us/magazine/2009.06.insidesharepoint.aspx

Now, hand me the bounty. ;)

丶情人眼里出诗心の 2024-08-01 16:31:19

抱歉,如果您想使用标准 UI,恐怕 ISPExternalBinaryProvider 是执行此操作的唯一方法。

PS 另一个重大挫折是备份/版本控制噩梦。 甚至不确定是否支持版本控制。

也许 SharePoint 2010 将有更好的方法来做到这一点......

Sorry to say, but ISPExternalBinaryProvider is the only way to do this i'm afraid if you want to use standard UI.

P.S. Another major setback is that is a backup / versioning nightmare. Not even sure if versioning is supported.

Perhaps SharePoint 2010 will have a better way to do this...

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