Spring for .NET Community Forums    

Go Back   Spring for .NET Community Forums > General > Core Container

Reply
 
Thread Tools Display Modes
  #1  
Old 01-14-2009, 02:04 AM
swalters swalters is offline
Member
Spring User
 
Join Date: May 2006
Posts: 33
Default Fluent Spring configuration

I thought I saw reference to a spring extension a few months ago to add fluent configuration of the spring container. But now I can only find a small project on Google Code that doesn't look like it's backed by the spring contributors.

Is this something that is on the immediate roadmap? I just spent the better part of a day wading through XML changes as part of a big project upgrade and I'm really wishing we had this so the compiler would do the hard work for me.

I read Mark's post - http://blog.springsource.com/2008/01...configuration/ - and had the impression that this was one of the more hotter areas of development. Is anyone working on this?

Thanks,

-Shane
Reply With Quote
  #2  
Old 01-14-2009, 06:54 AM
.ben .ben is offline
Senior Member
Spring User
 
Join Date: Oct 2005
Location: Belgium
Posts: 214
Default

I'm very intrested. If one has seen the ease of Fluent Nhibernate, you can only hope for this to come to Spring.Net configuration.
Reply With Quote
  #3  
Old 02-16-2009, 12:30 AM
Erich Eichinger Erich Eichinger is offline
Senior Member
Spring User
 
Join Date: Jan 2006
Location: Oslo, Norway
Posts: 1,337
Default

Hi,

be assured that we are aware of this and treat SharpConfig as top-prio. Nevertheless we are a bit short of time atm so any helping hand is greatly appreciated!

cheers,
Erich
Reply With Quote
  #4  
Old 02-16-2009, 01:32 PM
swalters swalters is offline
Member
Spring User
 
Join Date: May 2006
Posts: 33
Default

Hi Erich,

Will this be a Spring Extensions project? Has any work been done that I can review?

Thanks,

-Shane
Reply With Quote
  #5  
Old 03-26-2009, 09:54 PM
.ben .ben is offline
Senior Member
Spring User
 
Join Date: Oct 2005
Location: Belgium
Posts: 214
Default

*Bump*

Any news on this?
Reply With Quote
  #6  
Old 04-27-2009, 01:29 PM
BrunoCal BrunoCal is offline
Junior Member
New User
 
Join Date: Apr 2009
Posts: 2
Default

Hi,
I've implemented a small set of classes to allow us to register object definitions using a fluent interface.


It works really well in our scenarios, and the usage looks something like:

ContextRegistry.GetContext()
.Fluently()
.IncludeObjectsFromAssemblyOf<SomeObjectRepository >()
.Where(t => t.Namespace != "Some.Namespace")
.NameAs(t => t.Name)
.AsSingletonWhen(t => t is ISomeInterface)
.AddType<Repository<SomeObject2>>()
.Configure();

The idea behind is to use the autowiring but we have the posibility of use XML as well because the new generic context (with these definitions) will be a child of the current context.

The implementation is pretty simple.

What do you guys think? any input will be really appreciated.

Thanks
Bruno
Reply With Quote
  #7  
Old 04-27-2009, 02:24 PM
Erich Eichinger Erich Eichinger is offline
Senior Member
Spring User
 
Join Date: Jan 2006
Location: Oslo, Norway
Posts: 1,337
Default

Hi,

nice job, looks good! I had a very interesting pair programming session with Fabio Maulo from NHibernate right yesterday, who implemented his support for NHibernate Conversation per Business Transaction with Spring.NET. He came up with a very similar approach and plans to further refine it. You guys probably want to have a chat ;-).

Frankly SharpConfig as outlined by Mark Pollack in his blog seems more appealing to me, as the approach resulsts in a much more dense configuration, even less verbose than the fluent approach. Unfortunately this also means more work to implement. But asfaik is Mark already working on it. I will point him to this thread as he might want to comment himself on this.

cheers,
Erich
Reply With Quote
  #8  
Old 04-29-2009, 08:05 AM
BrunoCal BrunoCal is offline
Junior Member
New User
 
Join Date: Apr 2009
Posts: 2
Default

Hi,
Thanks Erich, I will try to speak with Fabio.
Also if you need a hand implementing some programatic interface let me know, I would like to colaborate with the proyect.
Thanks
Bruno
Reply With Quote
  #9  
Old 05-03-2009, 04:55 PM
aedenj aedenj is offline
Member
Spring User
 
Join Date: May 2008
Posts: 34
Default

While I wouldn't be good for leading the vision of this, once there is a stable direction I'd be more than willing to put in effort.

Cheers,
Aeden
Reply With Quote
  #10  
Old 05-25-2009, 08:15 PM
aedenj aedenj is offline
Member
Spring User
 
Join Date: May 2008
Posts: 34
Default

Just curious what the direction is on this because I'd be interested in helping out.

Cheers,
Aeden
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.