jcr

How do you restore a "versioned node" in a jackrabbit 2.1 repository?

Once a node has been deleted, how do you locate it so that you can restore it using jackrabbit or the jcr APIs? ...

Java Content Repository implementation: single-threaded, in-memory, read-only?

Does a Java Content Repository (JCR, specified in JSR-283) implementation with the following features exist? Single-threaded (does not create threads for background processing). In-memory (does not rely on external storage such as a database system or a filesystem). Possibly read-only (no need to support write operations — all content ...

NPE when i update custom node

Hi all I am trying to upgrade jackrabbit version in my project from 1.6 to 2.1.1. Some things from 2.1.1 are very usable. After transition on new version i get "magic" problems. I often catch NPE exception from inside jackrabbit api. After some investigations and tests i had found one of many problems. What i do in my test? I declare c...

Can't remove version in Jackrabbit

I'm trying to remove a version from the version history and I'm getting javax.jcr.ReferentialIntegrityException: Unable to remove version. At least once referenced. When I try to remove all references to the version it seems like there aren't any and still does not allow me to remove the version. I am sure that this is not the root vers...

Problems with hyphen in Jackrabbit XPath query

Firstly, let me just say that I'm very new to JSR-170 and Jackrabbit/Lucene in general. I have the following XPath query: //*[@sling:resourceType="users/user-profile" and jcr:contains(*/*/*,'sophie\-a')] order by @jcr:score descending I have a user named Sophie-Allen and a user named Sophie-Anne. Searching using the above query retu...

High-level Java filesystem content manipulation : old style vs. jcr ?

Hi, I was wondering, what is the best way to choose for managing text/binary content on filesystem? Typically when building web applications with a lot of multimedia binaries and other various text based content stored on filesystem, JDK 6 java.io is still too much low level. It will change with java 7 as you can see here thanks to n...

Custom JCR (Jackrabbit) node property type

Hi, I want to use an enum constant for a property value in jackrabbit. However the Node.setProperty() only accepts primitive types, String and Value as property value types. I looked through the ValueFactory interface, but that also seems like it can't help me. In other words I want to do this: node.setProperty("name", Enum.Const); ...

JCR (JSR-170) connector for Lotus Notes

I'm looking for JCR (JSR-170) connector for Lotus Notes Domino Server 7 for integration between our customer Domino server and our software. Does anybody has an experience in dealing with such JCR connector? I found only day.com connector but not sure it if fits me. ...

Simple JCR_SQL2 query returns nothing on Jackrabbit 2.1.1

Hi, I have this simple JCR_SQL2 query: SELECT * FROM [my:type] I'm running it like so: final QueryManager qMan = session.getWorkspace().getQueryManager(); final Query q = qMan.createQuery("SELECT * FROM [my:type]", Query.JCR_SQL2); final QueryResult qResult = q.execute(); return qResult.getNodes(); on a workspace which is indexed (a...

When to use JCR (content repository) over other options?

Hi, I'm trying to evaluate content repositories (JSR283) like Jackrabbit and ModShape but I must confess that I don't understand what problem resolves in first place and even if it is a good choice for the project. Which cases do you think is the best solution to apply? Is not the same thing as relational databases, except for the size? ...

JCR checkin/checkout operations

Hi guys, I'm just starting to work with JCR (apache jackrabbit), i want to ask simple question (because i coudn't find good tutorial for it): So for what do i need Node.checkout and Node.checkin methods? What do they mean? Thx ...

Jboss order loading problem

Hello to everybody) Imagine we have 2 wars to deploy. First war should load some data into JCR repository, or any other storage. Second war uses data that is loaded by first war in storage. Now we have situation when first war is successfully deployed, but it is in the middle of initialization process(loading data). Second war is start...

How to "embed" Fedora Repository for JUnit integration tests

The application in question uses Fedora 3.3. Unit tests depend on a local installation of Fedora and call web services at localhost:8080. That's not nice to run the tests in Hudson and the tests have been skipped since a very long time. I want to fix this. I do not want to install Fedora locally and I do not want to depend on the staging...