2012-07-27 68 views
1

在「標準」 WCF服務我會簡單地標記的操作方法有:是否可以配置自定義DataService <T>以允許模擬?

[OperationBehavior(Impersonation = ImpersonationOption.Allowed)] 

但隨着我的數據服務,我只要DataServiceHost打開得到一個InvalidOperationException:

The service operation 'ProcessRequestForMessage' that belongs to the contract with the 'IRequestHandler' name and the 'http://tempuri.org/' namespace does not allow impersonation. 

如何標記'ProcessRequestForMessage'以允許模仿?

回答