2016-07-15 6 views
0

IdentityServer3サーバーのセットアップがあり、データベースからクライアントおよびスコープ情報を取得するためにEntity Frameworkを使用するように構成されています。IdentityServer3 DiscoveryDocumentがロードされない

ShowInDiscoveryDocument = 0の場合、データベースに新しいスコープ(dbo.Scopes)を追加すると、すべてが正常であり、よく知られているドキュメントが正しく読み込まれます。しかし、ShowInDiscoveryDocument = 1、私は次のエラーを取得する場合:

Message: "An error has occurred.", 
ExceptionMessage: "The type initializer for 'IdentityServer3.EntityFramework.Entities.EntitiesMap' threw an exception.", 
ExceptionType: "System.TypeInitializationException", 
StackTrace: " at IdentityServer3.EntityFramework.Entities.EntitiesMap.ToModel(Scope s) at System.Linq.Enumerable.WhereSelectListIterator`2.MoveNext() at System.Linq.Enumerable.WhereEnumerableIterator`1.MoveNext() at System.Collections.Generic.List`1.InsertRange(Int32 index, IEnumerable`1 collection) at IdentityServer3.Core.Endpoints.DiscoveryEndpointController.d__11.MoveNext() in 
c:\local\identity\server3\IdentityServer3\source\Core\Endpoints\Connect\DiscoveryEndpointController.cs:line 89 --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Threading.Tasks.System.Web.Http908956.TaskHelpersExtensions.d__3`1.MoveNext() in c:\local\identity\server3\IdentityServer3\source\Core\Validation\ScopeValidator.cs:line 0 --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Web.Http.Controllers.ApiControllerActionInvoker.d__0.MoveNext() in c:\local\identity\server3\IdentityServer3\source\Core\Validation\ScopeValidator.cs:line 0 --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Web.Http.Controllers.ActionFilterResult.d__2.MoveNext() in c:\local\identity\server3\IdentityServer3\source\Core\Validation\ScopeValidator.cs:line 0 --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Web.Http.Dispatcher.HttpControllerDispatcher.d__1.MoveNext() in c:\local\identity\server3\IdentityServer3\source\Core\Validation\ScopeValidator.cs:line 0", 
    InnerException: { 
    Message: "An error has occurred.", 
    ExceptionMessage: "Could not load type 'AutoMapper.IMapperConfiguration' from assembly 'AutoMapper, Version=5.0.2.0, Culture=neutral, PublicKeyToken=be96cd2c38ef1005'.", 
    ExceptionType: "System.TypeLoadException", 
    StackTrace: " at IdentityServer3.EntityFramework.Entities.EntitiesMap..cctor()" 
+0

最新版のautomapperをIdSvr.EFが使用しているものよりも新しいものに更新しましたか? –

+0

バージョン5.0.0を使ってみましたが、これはIdsvrが使っていたと思います。それはうまくいかなかった。私も試しました5.0.2 –

+0

それはそれに対して構築されたものを使用してみませんか? IOW、ナゲットを更新しないでください。この問題のトラッカーには未解決の問題があります。 –

答えて

0

この問題が報告されていると私はソースに固定ナゲットパッケージがまだ修正されている場合、私は知らないと思います。

+0

まだありません。そして、このダイアログボックスをより多くの文字で埋めて、敵対的なSO警察が私に投稿させるようにする必要があります... * sigh * –

+0

2.5.1 NuGetがリリースされました。 –

+0

ありがとう、みんな! –

関連する問題