s#arp-architecture

S#arp Architecture

馋奶兔 提交于 2019-12-09 12:53:44
问题 Can someone share their experiences with s#arp architecture. we have decided to follow mvp pattern for the project. Is this okay to go with it ? The size of the project is medium. we are going to follow the tdd and ddd. Can anybody explain how to use this architecture means explain about the layers. we don't have enough time to go through with entire documentation. if anybody expalin particle with small example in short. please help me out!!! Thanks, Milind 回答1: The S#arp Architecture

Architectural question: In what assembly should I put which class, for a clean solution?

早过忘川 提交于 2019-12-06 10:56:43
问题 PREAMBLE: This is by far the longest post I've left here...but I think it's required in this case. I've had questions about these kinds of things for a long time: how to name assemblies, and how to divide up classes within them. I'd like to give an example of an application here, with only a bare minimum of classes to demonstrate what I'm trying to understand. Imagine an application that Accepts client messages, store them in a db, and then later dequeues them to an MTA server. It's a Web

ASP.NET MVC solution organization

你说的曾经没有我的故事 提交于 2019-12-04 23:44:45
问题 I'm looking to create a fairly large-scale ASP.NET MVC project and I want to break it out so that it's not all in one project and one assembly. I looked at how Oxite does their organization (http://oxite.codeplex.com/Wiki/View.aspx?title=architecture) but I was wondering how other people do it too. Any suggestions? Currently, I'm considering something very similiar to Oxite: Project - This project contains the model layer which includes models, configuration classes, and interfaces for

sharp architecture problem

佐手、 提交于 2019-12-04 15:27:15
I started to use the latest s#arp architecture (1.9.5.0). I sometimes add some data to the db via a console application using something like this: Repository<OriginalSequence> SequenceRepository = new Repository<OriginalSequence>(); ... SequenceRepository.SaveOrUpdate(Sequence); SequenceRepository.DbContext.CommitChanges(); NHibernateSession.Current.Flush(); NHibernateSession.Current.Clear(); Unfortunately, I get: ServiceLocator has not been initialized; I was trying to retrieve SharpArch.Data.NHibernate.ISessionFactoryKeyProvider This has to do with DI I think. which is usually only necessary

Best way to deploy an ASP.NET MVC app on IIS 7 / Server 2008?

社会主义新天地 提交于 2019-12-04 13:37:23
问题 So far, the only successful strategy I've been able to get by with is the following: Configure YOURAPP.Web to "Use Local IIS Web Server" and set "Project Url" = http://localhost/yourapp.web Click "Create Virtual Directory" In IIS Manager ensure that "Classic .NET App Pool" is selected Add wildcard mapping * named "ASP.NET-MVC" that points to IsapiModule BUT I don't really like the idea of having the full ASP.NET pipeline invoked when requesting any resource (javascript file, stylesheet, image

S#arp Architecture

允我心安 提交于 2019-12-03 16:07:19
Can someone share their experiences with s#arp architecture. we have decided to follow mvp pattern for the project. Is this okay to go with it ? The size of the project is medium. we are going to follow the tdd and ddd. Can anybody explain how to use this architecture means explain about the layers. we don't have enough time to go through with entire documentation. if anybody expalin particle with small example in short. please help me out!!! Thanks, Milind The S#arp Architecture combines ASP.NET MVC with other frameworks and tools like NHibernate 2.0.1 NHibernate.Validator Fluent NHibernate

How to implement historical versioning?

北慕城南 提交于 2019-12-03 13:54:45
问题 We are in the early stages of building a large C# MVC2 app (we also employ Sharp architecture and Nhibernate as part of the ecosystem) on SQL 2008 R2, and one of the requirements is that all database row versions are accessible for a given period of history. We have toyed with the idea of a layout similar to: id (PK) recordId versionId and having each edit to a record result in a new record being created with the same recordId and an incremented versionId. Record display would then be done

sortable telerik grid + NHibernate, IQueryable and ASP.NET MVC

≯℡__Kan透↙ 提交于 2019-12-01 13:37:00
I am trying to get a telerik grid to work (paging works fine). My view code looks like this: @(Html.Telerik().Grid(Model) .Name("Grid") .Columns(columns => { columns.Bound(o => o.ItemName.Text).Title("Name"); }) .Pageable(pager => pager.PageSize(20)) .Sortable() ) My controller looks like this: public ActionResult Index(GridCommand command) { return View(BlaRepository.GetBlas(command.PageSize, command.Page)); } The repository looks like this: public IQueryable<Bla> GetBlas(int PageSize, int Page) { var query = (from e in Session.Query<Bla>() select e).AsQueryable(); return query.Skip((Page - 1

Castle.Windsor and HttpContextWrapper

天大地大妈咪最大 提交于 2019-12-01 13:31:44
HttpContextWrapper and HttpContextBase, as explained here , were introduced to make HttpContext more mockable/testable. I'm trying to use it with S#arp Architecture , and hitting some problems. My MVC Controllers are set up to accept an HttpContextBase argument in the constructor, and during Application_Start, HttpContextBase is registered with Castle.Windor as follows: container.Register(Component.For<HttpContextBase>().UsingFactoryMethod( () => new HttpContextWrapper(HttpContext.Current))); This seemed to work OK for a bit, but then I realised Castle is only running that Factory method once,

sortable telerik grid + NHibernate, IQueryable and ASP.NET MVC

懵懂的女人 提交于 2019-12-01 12:00:22
问题 I am trying to get a telerik grid to work (paging works fine). My view code looks like this: @(Html.Telerik().Grid(Model) .Name("Grid") .Columns(columns => { columns.Bound(o => o.ItemName.Text).Title("Name"); }) .Pageable(pager => pager.PageSize(20)) .Sortable() ) My controller looks like this: public ActionResult Index(GridCommand command) { return View(BlaRepository.GetBlas(command.PageSize, command.Page)); } The repository looks like this: public IQueryable<Bla> GetBlas(int PageSize, int