NserviceBus throws exception when referencing a Nettiers assembly

Posted by IGoor on Stack Overflow See other posts from Stack Overflow or by IGoor
Published on 2010-04-01T12:08:38Z Indexed on 2010/04/01 12:13 UTC
Read the original article Hit count: 958

Filed under:
|
|

We use nettiers as a our data layer, and we recently have started looking at using NServiceBus, but we have hit a wall.

We have a windows service which hosts NSB and references our Nettiers assembly.

the service is throwing an exception when the following line is encountered.

var Bus = Configure.With().SpringBuilder()
            .XmlSerializer()
            .MsmqTransport()
                .IsTransactional(false)
                .PurgeOnStartup(false)
            .UnicastBus()
                .ImpersonateSender(false)
            .CreateBus()
            .Start();

the exceptions that is throw is:

Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.

the loader exception message is:

Could not load file or assembly 'Microsoft.Practices.Unity, Version=1.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.":"Microsoft.Practices.Unity, Version=1.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35

stacktrace is:

at System.Reflection.Module._GetTypesInternal(StackCrawlMark& stackMark)
at System.Reflection.Assembly.GetTypes()
at NServiceBus.Configure.<>c__DisplayClass1.<With>b__0(Assembly a) in d:\BuildAgent-03\work\672d81652eaca4e1\src\config\NServiceBus.Config\Configure.cs:line 122
at System.Array.ForEach[T](T[] array, Action`1 action)
at NServiceBus.Configure.With(Assembly[] assemblies) in d:\BuildAgent-03\work\672d81652eaca4e1\src\config\NServiceBus.Config\Configure.cs:line 122
at NServiceBus.Configure.With(IEnumerable`1 assemblies) in d:\BuildAgent-03\work\672d81652eaca4e1\src\config\NServiceBus.Config\Configure.cs:line 111
at NServiceBus.Configure.With(String probeDirectory) in d:\BuildAgent-03\work\672d81652eaca4e1\src\config\NServiceBus.Config\Configure.cs:line 101
at NServiceBus.Configure.With() in d:\BuildAgent-03\work\672d81652eaca4e1\src\config\NServiceBus.Config\Configure.cs:line 78
at MessageSender.Program.Main(String[] args) in C:\Development\NSBTest4\MessageSender\Program.cs:line 18

without the nettiers reference NSB works fine. Any idea what the problem is and how to solve it?

thanks.

© Stack Overflow or respective owner

Related posts about nservicebus

Related posts about nettiers