ibatis-user-cs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Clinton Begin" <clinton.be...@gmail.com>
Subject Domain classes from multiple assemblies...
Date Thu, 13 Jul 2006 21:11:48 GMT
Hi all,

I feel like Obi Wan meeting Vader (Gilles) and he's looking at me
saying: "When I met you I was but the learner. Now, *I* am the
master."   Sorry, couldn't resist the Star Wars quote.


I have a solution with a number of projects horizontally layered as
one would expect (Data, Service, Domain, Client etc).  But it is also
vertically partitioned into multiple vertical modules -- that is, for
each logical business area, there is a separate set of Data, Service,
Domain and Client projects.  Hence there are multiple "Domain"
projects containing my domain classes.

My iBATIS.NET persistence project is a single project with references
to the multiple domain projects.

So my persistence project dependencies look like this:

      |                |                |
     V               V              V
DomainA    DomainB    DomainC

The problem is, when I try to build the ISqlMapper instance with the
DOM builder, I get an exception (System.TypeLoadException).  If I
eliminate the SQL Maps that refer to the other domains, everything
works fine.

Here's the exception:

Test.ShouldGetAccountByAccountID : System.TypeInitializationException
: The type initializer for 'IbatisImpl.IbatisBaseRepository' threw an
  ----> IBatisNet.Common.Exceptions.ConfigurationException :
- The error occurred while loading SqlMap.
- initialize type alias
- The error occurred in <sqlMap resource="maps\Customer.xml"
xmlns="http://ibatis.apache.org/dataMapper" />.
- Check the MyNamespace.Customer.
  ----> System.TypeLoadException : Could not load type from string
value 'MyNamespace.Customer'.

(Environment:  NUnit GUI, .NET 2.0, C#, VS2005, SQL Server 2k5, iBATIS
Mapper 1.5)

Thoughts?  Help?


View raw message