Hello,

Yes I did that for both ddl files one in org.apache.jackrabbit.core.fs.db and the one in org.apache.jackrabbit.core.state.db. It would be really helpfull for me if you let me know the data entered during the configuration of the repository for the root element in the ${schemaObjectPrefix}FSENTRY table more specific the FSENTRY_NAME field.

The only difference that I can see on what we are doing is that I have build jackrabbit from source and I am using the jar file created, but not jlibrary which* is based* on jackrabbit. I am not sure if the implementation of jlibrary has added any layer above that is able to handle the case of oracle.

Antonis

nicolas.jouanin wrote:

Hi,

May be we misunderstood one what we do each other ...

I wrote oracle.ddl from mysql.dll which is the
org.apache.jackrabbit.core.state.db package.

This files contains DDL commands for creating tables:
xxx_BINVAL
xxx_NODE
xxx_PROPS
xxx_REFS
(where xxx is ${schemaObjectPrefix})

The error message you report (ORA-01400:cannot insert NULL into
("RABBIT"."REP_FSENTRY"."FSENTRY_NAME")) tells that you have an error when
trying to insert a NULL in column FSENTRY_NAME of table REP_FSENTRY, which
doesn't correspond to the tables I have on my side ...

So we are not talking about the same, or may be I missed something. Let me
know !

Regards,

Nicolas.

-----Message d'origine-----
De : Antonis Tsaltas [mailto:[EMAIL PROTECTED] Envoyé : mardi 20 décembre 2005 14:19
À : [email protected]
Objet : Re: Oracle as Persistence manager

Nicolas Jouanin wrote:

Hi,

As i said, may be it comes from the fact that the orginial ddl file (
mysql.ddl) uses CHAR type for table columns. I replaced them by VARCHAR2
columns.
Have your tried the same, or have you let let the CHAR datatype ?

I'll try to get back to CHAR datatype and try to run jLibrary with it.I'll
tell you the result.


2005/12/20, Antonis Tsaltas <[EMAIL PROTECTED]>:


nicolas.jouanin wrote:

Hi,



I read a previous thread concerning the use of Oracle with JackRabbit
(see below for copy).

As written, it seems not so simple to make it work.

Nevertheless, I wrote an oracle.ddl file (attached to this email)
based on mysql.ddl where I simply replaced some data types:

-          longblob -> blob

-          char -> varchar2 (Oracle doesn't like char)



Then I configured repository.xml correctly and used this configuration
to run this famous jLibrary software. To my surprise it worked, and
managed to create a repository, and add some nodes  : some jlibrary
folders, and some PDF documents node.



So , it may be need some more testing ; has someone achieved to make
jackrabbit run with Oracle, let me know.



Regards, Nicolas.









Original message:





Antonis Tsaltas

<[EMAIL PROTECTED]>to jackrabbit-dev

           More options     Dec 15 (3 days ago)

Dear all,



I am trying to use oracle with jackrabbit and the steps I have followed

are the following:



1) I have created the ddl files needed for creating the schemas with

oracle database similar to the existing ones and add them to the

appropriate package in the jackrabbit jar generated after the build.

However, when I tried to run a sample application I got nested

exceptions during the configuration of the repository and more specific

during the insertion of the root node due to the case that Oracle is

treating an emptry string and null as the same and the fsname of the

root node is empty string.



2) Next I tried to allow nullable values for the fsname as this will

only be the case for the root node and there will be no manual updates

to the repository. At this point it failed again when it tried to add an

entry '/meta' in fsentries table when it was checking if the parent of

this node exists (which is root node '/' ). There it performs the

following query:



select 1 from REP_FSENTRY where FSENTRY_PATH = '/' and

FSENTRY_NAME is null



which is in oracle equivalent with this:



select 1 from REP_FSENTRY where FSENTRY_PATH = '/' and

FSENTRY_NAME=''



and then it tries to insert the root node again but there is the logical

constraint:



create unique index ${schemaObjectPrefix}FSENTRY_IDX on

${schemaObjectPrefix}FSENTRY

(FSENTRY_PATH, FSENTRY_NAME).



Are there any suggestion or does anyone know if jackrabbit can work fine

with oracle db server?



Thanx























Stefan Guggisberg

to jackrabbit-dev

           More options     Dec 15 (3 days ago)

hi antonis

- Show quoted text -



well there's no reason why that shouldn't be the case in general.

but because of oracle's rather exotic and non-standard 'feature' of
treating

empty values as null you will probably have to write some oracle
specific
code :(



cheers

stefan







Thanx
Hi Nicolas,

I tried to do what you described in your mail from scratch, but the
exception that I received during configuration of the repository is the
following, which is due to Oracle's aproach of treating NULL and empty
string in the same way (for the root node tries to insert '/' as path
and '' as name where it fails):

org.apache.jackrabbit.core.config.ConfigurationException: File system
initialization failure.: failed to initialize file system: failed to
create folder entry: /: ORA-01400: cannot insert NULL into
("RABBIT"."REP_FSENTRY"."FSENTRY_NAME")
: failed to initialize file system: failed to create folder entry: /:
ORA-01400: cannot insert NULL into ("RABBIT"."REP_FSENTRY"."FSENTRY_NAME")

  at
org.apache.jackrabbit.core.config.FileSystemConfig.init(
FileSystemConfig.java:61)
  at
org.apache.jackrabbit.core.config.RepositoryConfig.init(
RepositoryConfig.java:250)
  at
org.apache.jackrabbit.core.config.RepositoryConfig.create(
RepositoryConfig.java:136)
  at
org.apache.jackrabbit.core.config.RepositoryConfig.create(
RepositoryConfig.java:78)
  at
org.apache.jackrabbit.core.jndi.BindableRepository.init(
BindableRepository.java:122)
  at
org.apache.jackrabbit.core.jndi.BindableRepository.create(
BindableRepository.java:110)
  at
org.apache.jackrabbit.core.jndi.RegistryHelper.registerRepository(
RegistryHelper.java:57)
  at ed.doc.mgt.test.RepositoryManager.<init>(RepositoryManager.java:82)
  at
ed.doc.mgt.test.RepositoryManager.configRep(RepositoryManager.java:465)
  at ed.doc.mgt.test.RepositoryManager.main(RepositoryManager.java:443)
Caused by: org.apache.jackrabbit.core.fs.FileSystemException: failed to
initialize file system: failed to create folder entry: /: ORA-01400:
cannot insert NULL into ("RABBIT"."REP_FSENTRY"."FSENTRY_NAME")

  at
org.apache.jackrabbit.core.fs.db.DbFileSystem.init(DbFileSystem.java:344)
  at
org.apache.jackrabbit.core.config.FileSystemConfig.init(
FileSystemConfig.java:55)
  ... 9 more
Caused by: org.apache.jackrabbit.core.fs.FileSystemException: failed to
create folder entry: /: ORA-01400: cannot insert NULL into
("RABBIT"."REP_FSENTRY"."FSENTRY_NAME")

  at
org.apache.jackrabbit.core.fs.db.DbFileSystem.createDeepFolder(
DbFileSystem.java:1256)
  at
org.apache.jackrabbit.core.fs.db.DbFileSystem.verifyRoodExists(
DbFileSystem.java:1225)
  at
org.apache.jackrabbit.core.fs.db.DbFileSystem.init(DbFileSystem.java:338)
  ... 10 more
Caused by: java.sql.SQLException: ORA-01400: cannot insert NULL into
("RABBIT"."REP_FSENTRY"."FSENTRY_NAME")





Hi,

Yes I have done that. However, the error does not seem to be relevant to that.


Reply via email to