Questions tagged [windsor-nhfacility]

The NHibernate facility slots into NHibernate and Castle AutoTx facility for LTM-transactions perfectly

The NHibernate facility slots into NHibernate and Castle AutoTx facility for LTM-transactions perfectly

See https://github.com/haf/Castle.Facilities.NHibernate/wiki/

19 questions
8
votes
2 answers

NHibernate (3.1.0.4000) NullReferenceException using Query<> and NHibernate Facility

I have a problem with NHibernate, I can't seem to find any solution for. In my project I have a simple entity (Batch), but whenever I try and run the following test, I get an exception. I've triede a couple of different ways to perform a similar…
5
votes
2 answers

Lazy loading with NHibernate Castle Facility

Do I have to close the ISession's that are generated by Castle's ISessionManager for NHibernate? How do I handle transactions with those ISession's? I'm still quite new to NHibernate. Edit: I would like to have lazy loading but I get this…
Daniel A. White
  • 187,200
  • 47
  • 362
  • 445
4
votes
0 answers

Creating an nhibernate session per web request with Castle.Facility.AutoTx and Castle.Facility.NHibernate

I am using Castle Windors and it's AutoTx and the NHibernate Facility by haf. Ultimately I want the benefits of ease of use of the Transaction attribute provided by AutoTx. (ASP.NET MVC 4 project). I am using…
Rob Gray
  • 3,186
  • 4
  • 33
  • 34
3
votes
2 answers

Transactions using Castle AutoTx Facility and NHibernate Facility

I'm trying to use the Castle NHibernate Facility with the AutoTx Facility. As a test, I'm throwing an exception in the middle of my service, to make sure the transaction is rolled back. However, the data is still persisted in the database. My…
Will
  • 2,086
  • 23
  • 30
3
votes
1 answer

Why would one want to use ISessionManager from CastleWindsor NHibernate facility?

I'm a beginner at both NHibernate and Castle Windsor but the current application I'm working on is making use of Castle Windsor's NHibernate facility Integration level 2 i.e. using the ISessionManager. I've compared what I need to do in order to…
DavidS
  • 2,179
  • 4
  • 26
  • 44
2
votes
1 answer

Injecting Correct ISessionFactory Into IRepository Using Castle Windsor and NHibernate Facility

I have three SQL Server databases that a single application retrieves data from. I am using NHibernate to retrieve data from the different databases. I have things set up so that each database has its own repository and class mappings in its own…
2
votes
3 answers

Castle Windsor Nhibernate Facility Lazy loading

I am migrating my mvc web app to use Nhibernate Facility to manage Nhibernate sessions. I am encountering this strange problem; When I register SessionWebModule under web.config/ httpmodules via:
kaivalya
  • 3,829
  • 9
  • 34
  • 43
2
votes
1 answer

Where do you download NHibernate Castle Facility?

I know it seems like a silly question, but its not clear from the castle project page/documentation. I would need a version compatible with the latest version of NHibernate (2.1.2). Should I get the latest source from the github trunk and build it,…
Sean Amos
  • 2,260
  • 19
  • 13
2
votes
1 answer

Using Castle Windsor and the NHibernate facility on shared hosting

I'm attempting to use Windsor and NHibernate in a medium trust environment and I'm running up against some problems with permissions. I have read through the other questions on this but I'm using Windsor's NHibernate facility which I haven't seen…
1
vote
1 answer

Configure Castle Windsor Container and Nhibernate using Nhibernate Facility

I'm trying to configure Nhibernate with Castle Windsor Container using Nhibernate Facility. But i'm having Here is my web.config
1
vote
1 answer

castle nh facility - 2 databases / 2 models / 2 factories

I have asked this on the castle list as i'm using the nh facility but it just dawned on me to ask it here too :) sorry for the cross posting. I'm using the nh facility to configure the following setup: i have 1 database which stores generic report…
1
vote
1 answer

c# - is it possible to use Castle.Facilities.NHibernate on .Net v3.5?

I'm developing an ASP.NET application using Windsor and NHibernate. I want to use Castle's new NHibernateFacility but I'm stuck on .NET 3.5 and NHibernateFacility along with AutoTx are targeted only to .NET 4. Is it safe to recompile them on v3.5?…
1
vote
1 answer

I upgraded NHibernate and now I get MSDTC issues when I'm not interested in using MSDTC

I upgraded my NHibernate libraries as well as Castle.Windsor. I also moved from using NHibernateIntegration to Castle.Facilities.NHibernate I implemented the advice at NHFacilities page here -…
PandaWood
  • 8,086
  • 9
  • 49
  • 54
1
vote
1 answer

Using the Windsor NHibernateFacility in a Wcf Service with a custom service behavior for creating transactions instead of the Transaction attribute

I am trying to use the Windsor NHibernate Facility for the first time in a Wcf service and replace the current manual registration of NHibernate so that there can be a consistent approach across all services. Current working approach Previously I…
0
votes
1 answer

Using Castle NHibernate Integration Facility with Castle Core 1.2

I'm working on a personal learning project to help me understand how to use Castle Windsor and Fluent NHibernate. So far written an ASP.NET MVC project which does some basic dependency injection of services into controllers. My project contains the…
Andrew
  • 885
  • 1
  • 12
  • 22
1
2