Bug in Enterprise Library

TNND,最近在用Enterprise Library的时候,需要自己实现他的IAuthorizationProvider接口,然后在用他的配置工具(EntLibConfig.exe)进行配置的时候,老是提示:

The type name XXX is not valid.

但是我看了几百遍,还是觉得应该实现方式没有什么问题。好在Enterprise Library带有源码,我直接把他配置工具的下面行注释掉:

// errors.Add(instance, name, SR.ExceptionTypeNotValid(typeName));



The problem is that some of the configuration settings have the [TypeValidation] attribute, which will attempt to check that the assembly qualified name of the type is a valid type. Unfortunately, this is running in an App Domain which is rooted in the EntLibConfig.exe directory, and so will only be able to resolves types in assemblies in that directory, or in the GAC.

而且提供的暂时解决方案居然就是直接注释掉那一行,他还友情提醒,因为没有检测,自己注意类型不要弄错了- –

唉…郁闷- –