功能事件处理程序多次调用Farm level功能 - sharepoint 2007 [英] Feature Event Handler called multiple times for Farm level feature - sharepoint 2007

查看:177
本文介绍了功能事件处理程序多次调用Farm level功能 - sharepoint 2007的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个农场范围的功能,它有一个事件处理程序。该功能在安装时默认激活。在安装了这个功能之后,我发现FeatureActivated事件已经被提出了多次(我总共有三个Web应用程序,不包括中央管理员,它被称为三次)。





任何想法?

解决方案

过去我也遇到过类似的问题。我在FeatureReceiver中创建了一个静态标志,指示是否已触发。



肮脏但有效。


I've a farm scoped feature which has an event handler. The feature is activated by default on installation. After I installed the feature I found that the FeatureActivated event has been raised mutiple times (I've three web apps in total excluding central admin and it is called three times).

Because of this the feature deployment is extremely slow (as I'm doing some webconfig modifications for each web application).

Any ideas?

解决方案

I have had a similar problem in the past. I created a static flag in the FeatureReceiver that indicates if it has triggered before.

Dirty, but effective.

这篇关于功能事件处理程序多次调用Farm level功能 - sharepoint 2007的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆