You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Dec 14, 2017. It is now read-only.
If I install the package from Nuget the DI Container gets setup as it should, and every plugin's dependency is registered.
But If I:
Download the source from Github
Build the assembly
Reference the Thinktecture.IdentityServer.WsFederation.dll for IdentityServer.
It causes an DI exception for the WsFederationController:
<Error>
<Message>An error has occurred.</Message>
<ExceptionMessage>
An error occurred when trying to create a controller of type 'WsFederationController'. Make sure that the controller has a parameterless public constructor.
</ExceptionMessage>
<ExceptionType>System.InvalidOperationException</ExceptionType>
<StackTrace>
at System.Web.Http.Dispatcher.DefaultHttpControllerActivator.Create(HttpRequestMessage request, HttpControllerDescriptor controllerDescriptor, Type controllerType) at System.Web.Http.Controllers.HttpControllerDescriptor.CreateController(HttpRequestMessage request) at System.Web.Http.Dispatcher.HttpControllerDispatcher.<SendAsync>d__1.MoveNext()
</StackTrace>
<InnerException>
<Message>An error has occurred.</Message>
<ExceptionMessage>
Type 'Thinktecture.IdentityServer.WsFederation.WsFederationController' does not have a default constructor
</ExceptionMessage>
<ExceptionType>System.ArgumentException</ExceptionType>
<StackTrace>
at System.Linq.Expressions.Expression.New(Type type) at System.Web.Http.Dispatcher.DefaultHttpControllerActivator.GetInstanceOrActivator(HttpRequestMessage request, Type controllerType, Func`1& activator) at System.Web.Http.Dispatcher.DefaultHttpControllerActivator.Create(HttpRequestMessage request, HttpControllerDescriptor controllerDescriptor, Type controllerType)
</StackTrace>
</InnerException>
</Error>
If more details needed please ask.
The text was updated successfully, but these errors were encountered:
The code is designed to be referenced via NuGet. If you must reference it directly then you must setup the right environment (such as the correct dependencies in the DI system).
Hmm, I understand.. I'm trying to debug the code for a better understanding of the WS Federation signout functionality. I've tryied in various ways but couldn't yet handle it the right way.
var configuration = new HttpConfiguration();
var builder = new ContainerBuilder();
var container = builder.Build();
configuration.DependencyResolver = new AutofacWebApiDependencyResolver(container);
DependencyResolver.SetResolver(new AutofacDependencyResolver(container));
app.UseAutofacMiddleware(container);
app.UseAutofacMvc();
app.UseAutofacWebApi(configuration);
Can you please show the bare minimum in order to make it work. Or at least point to the right direction. Thank you.
Yea, not sure. Perhaps the best way to debug into the ws-fed code would be to run the sample host that's in the ws-fed repo. It's referencing the code at the project level (and not via nuget).
If I install the package from Nuget the DI Container gets setup as it should, and every plugin's dependency is registered.
But If I:
It causes an DI exception for the
WsFederationController
:If more details needed please ask.
The text was updated successfully, but these errors were encountered: