All Questions
Tagged with nhibernate c#
12 questions
2
votes
3
answers
487
views
Should the domain layer be dependent on NHibernate?
Please see the code below:
public interface IUnitOfWorkWrite <TSession> : IDisposable
{
TSession Session { get; }
void Commit();
void Rollback();
...
8
votes
3
answers
7k
views
What is the "best" way to approach validation from the perspective of a DDD purist?
I recently asked this question.
I am trying to decide where to put the validation in a DDD app. I believe it should be done at every layer.
I am now concentrating on the Domain model. I was ...
1
vote
1
answer
3k
views
One Session Factory for the lifetime of an application or one Session Factory per Unit of Work?
Please see the code below, which creates a Session Factory per Unit Of Work:
public int Update(IdentityRoleView role)
{
var role2 = AutoMapper.Mapper.Map<IdentityRole>(role);
...
3
votes
2
answers
1k
views
Should I use nhibernate for a one row settings table
I am using nhibernate in a quite big project.
The system has a settings table which has 10 columns and one row, there is always a row and it should not be deleted only modified.
Concurrency can be a ...
3
votes
3
answers
257
views
Abstracton layer to control services access to denormalized db entity
Our db is optimized for minimum join count (partially denormalized). E.g. our User entity contains account data (nickname, facebook id, etc), user numerical statistics (total games played, total wins, ...
1
vote
2
answers
1k
views
Unit test DAO code using SQL Lite when the application database is Oracle
We have an application with Oracle backend. The DAO layer is written in C# and uses nHibernet to perform the data operations.
To unit test our DAO code, we use SQL Lite which creates the database ...
1
vote
1
answer
2k
views
.NET software design and Oracle ODP.NET UDT
I'm working on a new common .NET software design (mainly) for WCF-based web service applications with related client frontends (all written in C#). As far I've chosen some frameworks (NUnit,Autofac/...
3
votes
1
answer
1k
views
Abstraction Layer over ORM Generated Entities
I am learning LINQ to SQL (and planning to learn Entity Framework). Initially I used a abstraction layer to convert LINQ to SQL entities into a domain objects. Later I discovered the “Inheritance ...
1
vote
1
answer
1k
views
Is it ok to call external services or database inside the entity
I have "logic engine" which executes set of user configured steps. These steps are saved in the database as "Step" entities. The engine gets the first step and then executes steps until there are no ...
13
votes
2
answers
5k
views
Why is the Repository pattern needed in NHibernate?
I am reading the official Your first NHibernate based application.
While the tutorial is good and easy to follow, I am wondering why the Repository pattern is used.
In the various Add, Update, ...
8
votes
2
answers
1k
views
EF vs. NHibernate [closed]
In the past 2 years since I started writing business applications (before I did either high level front end or very low level systems programming), learned datasets, linq to sql, and now entity ...
2
votes
1
answer
2k
views
What is the benefit of using sharp architecture?
I'm working in a project that use nhibernate as orm. Is there any benefit for me to use sharp architecture? what is these benefits?