2016-09-22 9 views
0

こんにちは私は、GodaddyサーバーでホストされているLive wcf restサービスを使用してCRMオンライン2016に接続しようとしています。ライブサービスによるDynamics CRM接続でエラーが発生する

エラー:

System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.IdentityModel, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified. 

File name: 'Microsoft.IdentityModel, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' 

    at Microsoft.Xrm.Sdk.Client.ServiceMetadataUtility.RetrieveACSIssuerEndpoints(Uri trustUrl) 

    at Microsoft.Xrm.Sdk.Client.ServiceConfiguration`1.SetAuthenticationConfiguration() 

    at Microsoft.Xrm.Sdk.Client.ServiceConfiguration`1..ctor(Uri serviceUri, Boolean checkForSecondary) 

    at Microsoft.Xrm.Sdk.Client.OrganizationServiceConfiguration..ctor(Uri serviceUri, Boolean enableProxyTypes, Assembly assembly) 

    at Microsoft.Xrm.Sdk.Client.ServiceConfigurationFactory.CreateConfiguration[TService](Uri serviceUri, Boolean enableProxyTypes, Assembly assembly) 

    at Microsoft.Xrm.Sdk.Client.ServiceConfigurationFactory.CreateConfiguration[TService](Uri serviceUri) 

    at Microsoft.Xrm.Sdk.Client.ServiceProxy`1..ctor(Uri uri, Uri homeRealmUri, ClientCredentials clientCredentials, ClientCredentials deviceCredentials) 

    at PortalRestfulService.Service1.authentication(CRMCredential objauthentication) 



WRN: Assembly binding logging is turned OFF. 

To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1. 

Note: There is some performance penalty associated with assembly bind failure logging. 

To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog]. 

私にソリューションを提案してください。

答えて

1

IdentityModel dllをbinフォルダにコピーしてみてください。

おそらく、GodaddyのWCFサービスは共有アプリケーションプールを使用し、部分的な信頼で実行されるため、限られた権限セットで実行されるため、その他の問題が発生します。

localhostの部分信頼モードでサービスを再コンパイル/再テストしてみてください。恐らくこの問題が再現されます。

だから、解決策のいずれかのようになります。それは部分的に信頼罰金

  • ユーザーにあなたが欲しいほとんどすべてを行うことができます(フルVMのような)別のホスティングオプションを働くよう

      は(あなたのコードを変更し
    1. フルトラストでコードを実行する、アイデンティティモデルアセンブリをインストールする、など)。
  • +0

    こんにちは完全信頼モードです。これを解決する他の方法がありますか? –

    +0

    IdentityModel dllをbinフォルダにコピーしてみてください。 – Jordi

    関連する問題