Spring for .NET Community Forums    

Go Back   Spring for .NET Community Forums > General > NHibernate

Reply
 
Thread Tools Display Modes
  #1  
Old 11-28-2006, 10:31 PM
PropellerheadNYC PropellerheadNYC is offline
Junior Member
New User
 
Join Date: Nov 2006
Posts: 1
Default Broken Nightly Builds?

Hi All,

I'm trying to get started with Spring.Net and NHibernate, but I'm running into some difficulties. I'm starting with the NHibernate Spring integration build from last night (Spring.Data.NHibernate-20061128-0224).

I attempted to build the examples by:

1) removing the dead references to the core Spring.Net projects

2) replacing the missing dll references with refs to the libs in the lib/Net/2.0 directory (mostly Spring.Core, Spring.Data, and Spring.Aop)

3) the xcopy command in the Spring.Northwind.IntegrationTests project was failing due to the build actually happening in a different location. As a workaround, I just manually copied the Spring.Northwind.IntegrationTests.dll.config file to the build location since I knew I wasn't going to mess with it.

4) I removed the reference to the Spring.Data.NHibernate.Integration.Tests.dll.confi g file since it was nowhere to be found.

Once I did all that, the project appeared to build fine.

Next step, running the nunit tests. Using nunitGUI, I'm getting the following exception when running the Spring.Northwind.Integrationtests:
Code:
Spring.Northwind.IntegrationTests.FulfillmentServiceTests.ProcessCustomerViaTxProxyFactoryObject : System.Configuration.ConfigurationErrorsException : Error instantiating context 'spring.root'.
  ----> Spring.Objects.FatalObjectException : Cannot instantiate Type [Spring.Context.Support.XmlApplicationContext] using ctor [Void .ctor(System.String, Boolean, System.String[])] : 'Exception has been thrown by the target of an invocation.'
  ----> System.Reflection.TargetInvocationException : Exception has been thrown by the target of an invocation.
  ----> Spring.Objects.Factory.ObjectDefinitionStoreException : Error registering object with name 'DbProvider' defined in 'file [C:\Documents and Settings\salcoff.TRADING\My Documents\Misc Binaries\Spring.Data.NHibernate-20061128-0224\examples\Spring\Spring.Northwind\build\VS.Net.2005\Spring.Northwind.IntegrationTests\Debug\Dao.xml]' : Object class [Spring.Data.Support.SqlProvider, Spring.Data] not found.
<object id="DbProvider" type="Spring.Data.Support.SqlProvider, Spring.Data" xmlns="http://www.springframework.net"><property name="ConnectionString" value="Data Source=${db.datasource};Database=${db.database};User ID=${db.user};Password=${db.password};Tru...
  ----> System.TypeLoadException : Could not load type from string value 'Spring.Data.Support.SqlProvider, Spring.Data'.
  ----> System.TypeLoadException : Could not load type 'Spring.Data.Support.SqlProvider' from assembly 'Spring.Data, Version=2.1.1.0, Culture=neutral, PublicKeyToken=null'.
Which seems to indicate that the class SqlProvider is not found in the Spring.Data dll... Indeed, this class is not in the bundled Spring.Data dll.

I checked the nightly builds of the latest Spring.Net and this class is not included in the expected src directory or the dll, but it shows up in Fisheye.

Anyone know what's going on here?

Thanks,
Sam
Reply With Quote
  #2  
Old 11-29-2006, 12:33 AM
cameo_chen cameo_chen is offline
Junior Member
New User
 
Join Date: Nov 2006
Posts: 1
Default I meet the same problem?

I meet the same problem?Who give me the full example?my Email:sportxp@126.com .Thank you!
Reply With Quote
  #3  
Old 11-29-2006, 03:33 PM
Mark Pollack Mark Pollack is offline
Spring.NET Co-Lead
Spring TeamSpring User
 
Join Date: Sep 2004
Location: New York, NY
Posts: 1,603
Default

Hi Sam,

Ug, sorry about all this... please bear with me and I'll clean all this up asap. The SqlProvider class in indeed gone, the test code needs to change to use the new general provider mechanism. (At least there are docs for that . ) BTW, there is NHibernate 1.2 beta support in CVS - but I guess you saw it in fisheye...

Cheers,
Mark
Reply With Quote
  #4  
Old 02-13-2007, 01:54 PM
Mark Pollack Mark Pollack is offline
Spring.NET Co-Lead
Spring TeamSpring User
 
Join Date: Sep 2004
Location: New York, NY
Posts: 1,603
Default

Hi,

The example code is now cleaned up, should work for you out of the box once you make the db connection string changes.

Cheers,
Mark
Reply With Quote
  #5  
Old 03-07-2007, 11:39 PM
await await is offline
Junior Member
New User
 
Join Date: Mar 2007
Posts: 3
Default Latest Build Broken? Spring.Data.NHibernate12-20070306-1435

Hi I just tried downloading the latest build of Spring-nHibernate 1.2, and Spring.Data.NHibernate solution isn't compiling. I tried building a new solution by hand and was getting errors.

http://www.springframework.net/downl...70306-1435.zip

I'm just trying to get the samples running, so if anyone could be of help it would be appreciated.

Thanks,
-Andy

Here's the error Visual Studio was giving me.
Error 1 The type or namespace name 'HibernateAccessor' could not be found (are you missing a using directive or an assembly reference?) C:\svn\tools\Spring\nHibernate\src\Spring\Spring.D ata.NHibernate12\Data\NHibernate\Generic\Hibernate Template.cs 70 38 Spring.Data.NHibernate12.2005
Error 2 The type or namespace name 'ICommonHibernateOperations' could not be found (are you missing a using directive or an assembly reference?) C:\svn\tools\Spring\nHibernate\src\Spring\Spring.D ata.NHibernate12\Data\NHibernate\Generic\IHibernat eOperations.cs 41 45 Spring.Data.NHibernate12.2005
Error 3 The type or namespace name 'HibernateTemplate' does not exist in the namespace 'Spring.Data.NHibernate' (are you missing an assembly reference?) C:\svn\tools\Spring\nHibernate\src\Spring\Spring.D ata.NHibernate12\Data\NHibernate\Generic\Hibernate Template.cs 74 20 Spring.Data.NHibernate12.2005
Error 4 The type or namespace name 'TemplateFlushMode' could not be found (are you missing a using directive or an assembly reference?) C:\svn\tools\Spring\nHibernate\src\Spring\Spring.D ata.NHibernate12\Data\NHibernate\Generic\Hibernate Template.cs 182 25 Spring.Data.NHibernate12.2005
Error 5 The type or namespace name 'HibernateTemplate' does not exist in the namespace 'Spring.Data.NHibernate' (are you missing an assembly reference?) C:\svn\tools\Spring\nHibernate\src\Spring\Spring.D ata.NHibernate12\Data\NHibernate\Generic\Hibernate Template.cs 335 27 Spring.Data.NHibernate12.2005
Reply With Quote
  #6  
Old 03-08-2007, 01:26 AM
await await is offline
Junior Member
New User
 
Join Date: Mar 2007
Posts: 3
Default Figured it out

So I figured out my problem. The distribution expects you to unzip both the 1.0 and 1.2 versions into a directory called Spring.Data.NHibernate .

It would be nice if the solution could point to the source via a relative path, or the distribution should be create 'Spring.Data.NHibernate' as a top level directory.
Reply With Quote
  #7  
Old 03-08-2007, 01:16 PM
Mark Pollack Mark Pollack is offline
Spring.NET Co-Lead
Spring TeamSpring User
 
Join Date: Sep 2004
Location: New York, NY
Posts: 1,603
Default

Hi,
Yes, this keeps coming up so something like you suggest is in order. Sorry for the trouble.
Cheers,
Mark
Reply With Quote
  #8  
Old 03-09-2007, 11:08 AM
nokiola nokiola is offline
Junior Member
Spring User
 
Join Date: Mar 2006
Posts: 25
Default

I, too, receive "Error instantiating context 'spring.root'."

Has this issue been fixed?

Regards,
Robert
Reply With Quote
  #9  
Old 03-09-2007, 11:56 AM
Mark Pollack Mark Pollack is offline
Spring.NET Co-Lead
Spring TeamSpring User
 
Join Date: Sep 2004
Location: New York, NY
Posts: 1,603
Default

Hi Robert,
The solution to the problem, which I'm not sure is the same as what you are reporting, is to download both NH 1.0 and NH 1.2 distributions, install them side-by-side and then you will be able to compile NH1.2 The reason is that the NH 1.2 solution refers to source files in the NH 1.0 directory. This was done to avoid duplication in CVS and a repackaging will be made to avoid this issue in the near future. Hope this helps.
Cheers,
Mark
Reply With Quote
  #10  
Old 03-09-2007, 01:41 PM
nokiola nokiola is offline
Junior Member
Spring User
 
Join Date: Mar 2006
Posts: 25
Default

Mark,

I used for testing the debugging assemblies resulted from continuous integration server, which produced Spring.Data.NHibernate12-20070306-1435.zip in http://www.springframework.net/downl....NHibernate12/.

I did not download any source code for self-compile.

So, you suggest to download from CVS the source and compile myself taking into consideration your recent notes?

BTW, I have another question which I wanted to ask you for quite some time: is there any particular reason for which Spring.NET team keeps using CVS instead of SVN?

Thanks,
Robert
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 12:10 AM.


Contegix provides first-class managed hosting and partial sponsorship of these forums.

Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.