jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Taeho Kang <tka...@gmail.com>
Subject Re: Using different ddl for other DB's?
Date Tue, 14 Apr 2009 10:01:55 GMT
Wow, many thanks for your prompt reply.
I'm going to
use org.apache.jackrabbit.core.state.db.SimpleDbPersistenceManager, which
lets me specify many options such as JDBC driver, schema name, and etc.

Now, since I'm testing on a local environment, where should I place my
schema.ddl file?

I tried placing my schema.ddl file in java classpath, but It hasn't worked
so far....
- "javax.jcr.RepositoryException: Configuration error: unknown schema

Please note that I set my java classpath with System.setProperty(..) method
in my main() method.

Do you have any tips?


On Tue, Apr 14, 2009 at 5:15 PM, Alexander Klimetschek <aklimets@day.com>wrote:

> On Tue, Apr 14, 2009 at 9:31 AM, Taeho Kang <tkang1@gmail.com> wrote:
> > I'm faced with a problem of setting up JackRabbit with a "not-so-common"
> > database system.
> > I know I have to write a new schema.ddl file, but I don't know how it can
> be
> > loaded.
> > In which directory/package should I place the new ddl file?
> It's loaded from the classpath and is placed in the same java package
> as the class using it (persistence manager or database filesystem).
> The only thing mentioned in the repository xml is the basename of the
> file. The classpath depends on the servlet container / jvm context,
> but for a webapp you can put it into WEB-INF/classes. For a bundle
> persistence manager this gives you:
> WEB-INF/classes/org/apache/jackrabbit/core/persistence/bundle/<myschema>.ddl
> Please note that you might have to write your own
> BundleDbPersistenceManager if the database behaves very different. You
> would subclass it and overwrite some of the methods to align data
> types and other things like that.
> You should also look at the code - here are the svn trunk links for
> the mentioned implementations and their built-in schema files:
> Bundle DB PM:
> https://svn.apache.org/repos/asf/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/persistence/bundle/
> https://svn.apache.org/repos/asf/jackrabbit/trunk/jackrabbit-core/src/main/resources/org/apache/jackrabbit/core/persistence/bundle/
> DB Filesystem:
> https://svn.apache.org/repos/asf/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/fs/db/
> https://svn.apache.org/repos/asf/jackrabbit/trunk/jackrabbit-core/src/main/resources/org/apache/jackrabbit/core/fs/db/
> Regards,
> Alex
> --
> Alexander Klimetschek
> alexander.klimetschek@day.com

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message