Windsor logging facility

2009-02-10 Thread Flominator
Hi there, yesterday I tried to implement log4net for my controllers. As expected I ran into some problems: 1. When simply using Logger.Debug(bla bla); the property Logger at my controller refers to Castle.Core.Logging.NullLogger 2. When trying the suggestion from

Re: Fill PropertyBag from BaseController

2009-02-10 Thread Ben Lovell
Could you override the propertybag and do your stuff there? I've not got VS open in front of me so that's a question as much as an answer ;) On Tue, Feb 10, 2009 at 7:59 AM, Flominator flomina...@gmx.net wrote: Hi there, is there any way to fill some fields in the PropertyBag within my

How to integrate Castle ActiveRecord and WCF using Windsor?

2009-02-10 Thread crios...@gmail.com
Hey guys, Can anyone provide working snippet for integration AR and WCF services using windsor container (facility perhaps?) for PerCall (per request) model?.. Thank you in advance! :) --~--~-~--~~~---~--~~ You received this message because you are subscribed to

Re: Fill PropertyBag from BaseController

2009-02-10 Thread Lee Henson
One choice is to use a filter. [Filter(ExecuteWhen.BeforeAction, typeof(IPreloadBaseControllerPropertyBagFilter)] public class BaseController { } public class PreloadBaseControllerPropertyBagFilter : IFilter { public virtual bool Perform(.) {

Re: Error with BaseHttpHandler.cs

2009-02-10 Thread mausch
Please don't cross-post (http://forum.castleproject.org/viewtopic.php? t=5131). Use only this mailing list, the forum has been deprecated. On Feb 9, 8:57 pm, eyal ebarda...@gmail.com wrote: Hi All I encountered an error that is generated on Monorail library class BaseHttpHandler.cs I have

Re: Windsor logging facility

2009-02-10 Thread mausch
Refer to this sample app: http://svn.castleproject.org:8080/svn/castle/trunk/MonoRail/TempWeb/ In particular, see the initialization code: http://svn.castleproject.org:8080/svn/castle/trunk/MonoRail/TempWeb/Global.asax.cs On Feb 10, 7:17 am, Flominator flomina...@gmx.net wrote: Hi there,

Re: ARDataBinder and Version fields

2009-02-10 Thread Markus Zywitza
Sorry for the delay. Can you please elaborate on what you need to do? Any checks that are done by NH (not-null, uniqueness, version etc.) are only performed while flushing. Calling Save() won't do anything within a SessionScope when the object is already persistent (this is the case when you

Re: How to integrate Castle ActiveRecord and WCF using Windsor?

2009-02-10 Thread Craig Neuwirt
They are independent. You should be able to configure them independently. I suspect what you are looking for is how to manage session/transaction scope per request. If you look at the WcfFacility tests you will find a UnitOfWorkBehavior which shows you how to create the plumbing you need. For

Re: ARDataBinder and Version fields

2009-02-10 Thread Simon Laroche
This is my scenario: 1. Version field is a hidden field in the form. 2. When I bind using ARDataBinder, the binder correctly sets the version field to whatever is in the form. 3. I would like to get an StaleObjectStateException when I flush the session if the version has changed. If I use the

Field not found: 'NVelocity.Runtime.Directive.Directive.runtimeServices' exception after moving from RC3 to trunk build 1040

2009-02-10 Thread Alexandra Tikhonova
Hi We have moved our project from RC3 to the trunk build 1040. After fixing some breaking changes like objects renaming and removing monorail http module, we managed to build our project. But when we run it we got the following exception: Exception Details: System.MissingFieldException: Field

Form isn't loading on grid selection

2009-02-10 Thread M Kenyon II
I have a MonoRail page with a grid and a form. When you enter data into the form and click save, it creates a row in the grid. If you double click on an item in the grid, it does a post back and should load the form. however, even though the data gets collected, it doesn't show. I have this code

About URL Routing

2009-02-10 Thread eyal
Hi All, I am interested in re-writing some of my urls to make them url friendly. I found this blog http://using.castleproject.org/display/MR/Routing+Overview My agenda is to convert the following: .../controllerName/searchresult.ashx?categoryId=23 into .../controllerName/categoryName where

Remoting facility : access remote component without client container

2009-02-10 Thread nicomn
Hi all, I want to distribute components with Remoting infrastructure. My components use Automatic Transaction Management facility associated with Nhibernate facility. Here a small example : Code: [Transactional] public class MyService : MarshalByRefObject, IMyService { private

Re: Fill PropertyBag from BaseController

2009-02-10 Thread Jorge Barnaby Rubio
I do it this way: public class BaseSiteController : ARSmartDispatcherController { public override void Initialize() { base.Initialize(); PropertyBag[siteCharset] = value; } } Hope it helps! yorch. On Feb 10, 5:28 am, Lee Henson lee.m.hen...@gmail.com wrote: One

Re: About URL Routing

2009-02-10 Thread Jimmy Shimizu
the UrlHelper will be able to generate urls if you have a matching rule for it. $Url.For(%{controller='product', action='view', params={name='ProductName'}}) would generate a URL if you have a valid route, I guess like this: RoutingModuleEx.Engine.Add( new PatternRoute(/controller/name)

Re: About URL Routing

2009-02-10 Thread eyal
I looked into your suggestions and that is what I decided to do: #foreach($Product in $Products) li$Url.Link($Product.Name, %{controller='products', action='searchresult', params={id=$Product.Id, name=$Product.Name}})/ li #end public static void Register(IRoutingRuleContainer rules)

Re: About URL Routing

2009-02-10 Thread eyal
I also forgot to mention that $Url.Link is now replacing an html a herf... tag (see code below). I noticed that with $Url.Link the parameter productId is not being passed into SearchResult(int productId). Not sure why. I think that this is the cause of the problem. Any ideas? #foreach($Product

Re: About URL Routing

2009-02-10 Thread eyal
Now I'm closer to a real solution see changes: public static void Register(IRoutingRuleContainer rules) { rules.Add(new PatternRoute(/controller/name/id/ action.ashx) .DefaultForArea().IsEmpty .DefaultForAction().Is(searchresult)

Re: Upgrading RC2 to Trunk

2009-02-10 Thread Ken Egozi
Hi Nicholas. I'll try to address your problems: * MonoRailHttpHandler and CurrentContext: The monorail's Context class has been broken down into the EngineContext and the ControllerContext. you can get a hold of these using MonoRailHttpHandler *Factory*.Current*Engine*Context, and