1

I keep getting the following error:

Method not found: 'Void Castle.MicroKernel.ComponentActivator.ComponentActivatorException..ctor

this is from the following initialization code in global.asax:

    private void ConfigureContainer()
    {
        _container = new WindsorContainer();

        _container.Register(Component.For<IWindsorContainer>().Instance(_container))
            .AddFacility<WcfFacility>()
            .Register(Component.For<ISonatribeCommandService>()
                          .AsWcfClient(DefaultClientModel
                          .On(WcfEndpoint.FromConfiguration("commandServiceClient")))
                          .LifestyleTransient())
            .Install(FromAssembly.InDirectory(new AssemblyFilter(HttpRuntime.BinDirectory, "Sonatribe*.dll")));

    }

my system.servicemodel section in web.config looks like:

  <system.serviceModel>
    <serviceHostingEnvironment aspNetCompatibilityEnabled="true" />
    <client>
      <endpoint address="http://****.com/SonatribeCommandService.svc" binding="basicHttpBinding" contract="CommandService.ISonatribeCommandService" name="commandServiceClient"></endpoint>
    </client>
  </system.serviceModel>

The service works fine when using the add web reference method.

UPDATE:

I also tried doing the config method too:

<configuration>
  <components>
    <component 
      id="commandService" 
      type="CommandService.SonatribeCommandService, CommandService"
      wcfEndpointConfiguration="commandServiceClient" />
  </components>
</configuration>

Any ideas?

1 Answers1

2

It looks like you're using incompatible versions of Windsor and the facility. Make sure you're using version of WCF Facility that was meant to be used with the version of Windsor you have.

Krzysztof Kozmic
  • 27,267
  • 12
  • 73
  • 115
  • That doesn't make it any less likely, especially if you used nuget UI. Make sure they both have the same version. – Krzysztof Kozmic Nov 20 '11 at 23:08
  • sorry, deleted, re-got and then rebuilt –  Nov 21 '11 at 10:03
  • gah: –  Nov 21 '11 at 10:05
  • i'm just going to go back to running my own builds... thanks for helping –  Nov 21 '11 at 10:23
  • Why use your own builds rather than official ones? Just upgrade the WCF Facility to RC1, right? – Krzysztof Kozmic Nov 21 '11 at 11:18
  • that's what i was using - i'm up and running now using my own build from github. –  Nov 21 '11 at 11:52
  • Right. Why? Are you saying the RC1 of WCF Facility (3.0.0.3001) together with the same version of Windsor and Core were giving you that issue? – Krzysztof Kozmic Nov 21 '11 at 22:39
  • Odd, I'm using it on my project with no issue. Do you think you could get me a test that reproduces that? – Krzysztof Kozmic Nov 22 '11 at 20:55
  • All i'm doing is using nuget to install the wcf facility rc and it pulls in different versions of the dlls as is defined in the xml snippet from the packages.config above. –  Nov 23 '11 at 09:39
  • i don't suppose you know what is going on here: http://stackoverflow.com/questions/8215275/wcffacility-sequence-contains-no-elements as well do you? –  Nov 23 '11 at 09:39