jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alexander Klimetschek" <aklim...@day.com>
Subject Re: Connection pooling
Date Wed, 16 Jul 2008 11:18:19 GMT
I think it is a good idea, Jukka has also already given some ideas on
how to implement it in JCR-1456. A patch is always welcome, especially
now, since most core developers are focused on other things and 1.5 is
not so clearly on the horizon ;-)

Regards,
Alex

On Wed, Jul 16, 2008 at 2:33 AM, Matej Knopp <matej.knopp@gmail.com> wrote:
> Hi,
>
> we've encountered a serious problem with jackrabbit - keeping a
> database connection for each active workspace.
> A jira entry already exists [1] and it's targetted for 1.5, but so far
> there hasn't seem to be much activity.
>
> I'm willing to provide a patch that might be of some help to you, but
> first I'd like to have some things clarified of how the thing should
> work (from user perspective).
>
> My idea so far is to have new config section (toplevel, inside
> <Repository>) that would allow to register data sources
>
> Something like
>
>        <DataSource id="ds1" class="com.mypackage.MyDataSource">
>                <param name="url" value="jdbc:postgresql:jackrabbittest"/>
>                <param name="user" value="postgres"/>
>                <param name="password" value="postgres"/>
>        </DataSource>
>
> Multiple data sources could be defined per repository.
>
> Jackrabbit would create and manage data source instances (each class
> is required to implement DataSource interface).
>
> All components that require a SQL connection would have dataSource
> attribute that would specify the data source instance.
>
> i.e.
>
>        <PersistenceManager
> class="org.apache.jackrabbit.core.persistence.bundle.PostgreSQLPersistenceManager">
>                <param name="dataSource" value="ds1"/>
>                <param name="schemaObjectPrefix" value="${wsp.name}_"/>
>                <param name="externalBLOBs" value="false"/>
>        </PersistenceManager>
>
> Alternatively there might be also a way to register data source per
> workspace, so the instance would be workspace specific. Though I
> personally don't see much value in this.
>
> It would be great to get any feedback on this.
>
> Kind regards,
> -Matej Knopp
>
> [1] https://issues.apache.org/jira/browse/JCR-1456
>



-- 
Alexander Klimetschek
alexander.klimetschek@day.com

Mime
View raw message