struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Wes Wannemacher <w...@wantii.com>
Subject Re: [OT] Searching for data access framework.
Date Mon, 05 Dec 2011 17:22:30 GMT
On Mon, Dec 5, 2011 at 12:12 PM, Balwinder <balwinder.mca@gmail.com> wrote:
> Hi Wes,
>
> What I need is something like, if I want to access data from a database, i
> can use SQL, but if i change the source to LDAP then the access mechanism
> will change from SQL to LDAP specifics, now if the same data goes to flat
> file than again my mechanism will change, so all I need is some framework
> that if when source is changed its access mechanism should remain same. Hope
> this explains what I am looking for.
>

Based on that, I am going to reiterate my original pointer to the DAO
pattern. What you are looking for (IMO) is too high-level to be be
implemented by a framework. There are ambitious attempts, such as
spring-data (http://www.springsource.org/spring-data). However, you
will see that they don't mention LDAP support. Conversely, if you read
the original link about the DAO *pattern* and implement that pattern
using a good IoC (spring), you will achieve your goal with very little
effort. Then, you will find that spring / struts play nicely together
and you will be very happy. As a reassurance, I use the DAO approach
with IoC and have a library, developed internally, that we use to
manage security. This allows us to retrieve users from a database, if
the database modules are wired in, or use LDAP if the LDAP / Active
Directory modules are wired in.

-Wes

-- 
Wes Wannemacher

Head Engineer, WanTii, Inc.
Need Training? Struts, Spring, Maven, Tomcat...
Ask me for a quote!

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message