Zhang, Larry (L.) wrote:
I have a user object whose data is from three resources: Db2, LDAP, and
other flat file. Per dao pattern, do you think I should have three daos
or one dao to encapsulate the data access implications?
Depends on what is easier for you. This will not effect your code if
2008/2/4, Zhang, Larry (L.) <[EMAIL PROTECTED]>:
> Sorry if this is not too on topic.
>
> I have a user object whose data is from three resources: Db2, LDAP, and
> other flat file. Per dao pattern, do you think I should have three daos
> or one dao to encapsulate the data acc
Sorry if this is not too on topic.
I have a user object whose data is from three resources: Db2, LDAP, and
other flat file. Per dao pattern, do you think I should have three daos
or one dao to encapsulate the data access implications
Hello Darren,
I'm aggree with Larry. If you want you can see Architecture shema with
Service/DAO pattern in my open source project Gestcv at
http://gestcv.sourceforge.net/fr/architecture.html (sorry it's in frensh).
You can download the application WEB to see how I use Spring w
On 9/11/06, Darren Hall <[EMAIL PROTECTED]> wrote:
So, should I use the datasource functionality provided in struts, or should
I "roll my own" database connection solution by creating a datasource
factory that can be used to retrieve connections?
I wouldn't do either. If you can, use Spring to
quick question.
I'm using struts 1.2.9 and I need to implement a database connection for my
web application and wanted to use a standard DAO pattern (this is due to the
fact that I will be using connection pooling as well as other datastores to
store application data, and want to decoupl
different underlying API using a single
consistent data access API.
Interestingly, the JDBC API is another application of the DAO pattern.
In that realm, you have a set of interfaces, and database vendors
implement them in a way that makes it possible to use them
interchangeably – for the most part
Larry Meadors wrote:
You can (and should) use the DAO pattern with Hibernate, too.
So true, plus a good DAO interface can decouple your database access
implementation and the rest of your app, so that you can switch from
hibernate to ibatis or plain jdbc or whatever without having to make
Whats about a thread local variable to store the connection instead of
as instance variable ?
On 8/24/05, Gareth Evans <[EMAIL PROTECTED]> wrote:
> Hi Paul,
>
> How about using a DBCP, that way the connections are always there, a getting
> a connection each time
> you need to do a unit of work b
Hi Paul,
How about using a DBCP, that way the connections are always there, a getting a connection each time
you need to do a unit of work becomes less of an overhead. With dbcp you can create your connection
by using an xml file usually named 'something.jocl', drop this into you classpath an
You can (and should) use the DAO pattern with Hibernate, too.
The iBATIS DAO even has built-in support for hibernate (of course, it
has support for sql maps, too).
Larry
On 8/23/05, Paul Benedict <[EMAIL PROTECTED]> wrote:
> Erik,
>
> Oh, I have worked on a project whe
Erik,
Oh, I have worked on a project where that was the
pattern I designed for myself!! One accepted a
connection for transactions, the other for
self-contained singleton executions. Yup, it's a great
pattern.
You raise an interesting point. I never thought about
using a middle-man between my bus
Original Message-
From: Paul Benedict <[EMAIL PROTECTED]>
Sent: Aug 23, 2005 6:35 PM
To: user@struts.apache.org
Subject: [OT] DAO Pattern in Struts
Guys,
This is off-topic but I need your help. There are some
good programmers here and I would like to receive some
advice back. I a
Have you looked at using something like the iBATIS DAO?
I think it could save you alot of pain.
One thing to watch out for is thread safety - putting a connection on
an instance (especially a shared instance) is pretty risky, especially
when you start thinking about transactions and the like...th
Guys,
This is off-topic but I need your help. There are some
good programmers here and I would like to receive some
advice back. I am sure there's a simple answer to it.
My Struts app is a multitier app (Web -> Business ->
DAO) and it uses Jakarta Commons DbUtils for the DAO
layer. My DAO methods
Not sure why, but I have never had the difficulty of maintenance being
held up because of appropriate uses of interfaces. I have had the
opposite happen lots of times. I am a stickler for the interface
approach to most classes. I am even thinking of foregoing entirely the
use of the System c
Adam Hardy wrote the following on 10/9/2004 7:34 AM:
However I have never come across a situation where anybody has changed
the implementation when doing an upgrade to their application. It sounds
good, but IMHO, never happens. Would be interested to find out otherwise :)
All of my classes implem
for comments on DAO pattern implementation
Dear all,
I've contemplated two ways of implementing DAO pattern; and I'm unable
to decide which is better :) Any comments on pros and cons of these
two approaches will be greatly appericiated.
Implementation 1: Have IDAO interface and let all t
nsaje original-
De: Marco Mistroni [mailto:[EMAIL PROTECTED]
Enviado el: viernes, 08 de octubre de 2004 16:21
Para: 'Struts Users Mailing List'; 'atta-ur rehman'
Asunto: RE: [OT] Request for comments on DAO pattern implementation
Hello,
My 2 cents.. go for the inter
Subject: [OT] Request for comments on DAO pattern implementation
Dear all,
I've contemplated two ways of implementing DAO pattern; and I'm unable
to decide which is better :) Any comments on pros and cons of these
two approaches will be greatly appericiated.
Implementation 1: Have IDAO
Dear all,
I've contemplated two ways of implementing DAO pattern; and I'm unable
to decide which is better :) Any comments on pros and cons of these
two approaches will be greatly appericiated.
Implementation 1: Have IDAO interface and let all the DAO objects
implement this inter
21 matches
Mail list logo