You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by "Brook, Andy" <an...@mcgraw-hill.com> on 2001/06/05 13:56:04 UTC

Custom data source properties

Hi all,
Im using JDataConnect with struts, all working fine except there are some
'custom' properties that the driver supports that I want to set.  In this
instance Unicode support, but it could be anything.  

Ive mod'd the necessary code for 'data-source' to reference an
'extPropsFile' attribute (eg extPropsFile=myCustomDriver.properties) and
load it from the root of the webapp classes root, adding properties found
therein to the properties list built from the other data-source attributes
and passed onto the driver.

My main reason for going to an external properties file is that there are
always custom properties that are peculiar to drivers, polluting the
data-source attributes to support them all is in my view not the way to go.

I can appreciate trying to keep the data-source attribute list as concrete
as possible is a good thing, but still.....

Any comments on this approach?

If its seen to be useful Ill happily post the changes, its not much code.

TTFN
andy.

andy_brook@mcgraw-hill.com
import com.mh.theViewsExpressedHereinAreMyOwnNotThatOfMyCompany;