techie2k | 16 Sep 09:18 2014
Picon

Unable to impersonate - Jackrabbit

I have custom type node /et:document /which needs to shared among some users
in jackrabbit repository.

But when I try to impersonate as superuser and assign to each user, a
defined property /sharedWithMe/, getting *failed login exception*.

Log in as application user,

/SimpleCredentials credentials = new SimpleCredentials(userName,
password.toCharArray());
Session session = repository.login(credentials, "default");/

Trying to share documents(with property added to user node)

/SimpleCredentials credentials = new SimpleCredentials("superuser",
"superuser".toCharArray());
Session adminUser = session.impersonate(credentials);
UserManager userManager = ((JackrabbitSession) adminUser).getUserManager();

for(String userID : users) {
    User user = (User) userManager.getAuthorizable(userID);
    Value value = vf.createValue(docPath);
    Value[] sharedDocsPath =  user.getProperty("sharedWithMe");
    int shareDocIndex = 0;
    Value[] revisedSharedDocPath = null;

    if (null != sharedDocsPath && sharedDocsPath.length > 0) {
        revisedSharedDocPath = new Value[sharedDocsPath.length + 1];

        for (Value v : sharedDocsPath) {
(Continue reading)

Tomasz Kleszczyński | 12 Sep 13:13 2014

Using two or more sessions within one XA Transaction

Hello, 

Does anybody have experience with using two sessions in one XA Transaction?
JCR specification describes using one session and multiple transactions. But
how about the opposite way? Is this case not supported or there may be bugs
in Jackrabbit in this area?

First tests have shown that such usage doesn't work as expected. State of
one session leaks to another one.
Here's attached my test case:
https://issues.apache.org/jira/secure/attachment/12666761/CheckinCloneTest.java

Best regards,
Tomek

--
View this message in context: http://jackrabbit.510166.n4.nabble.com/Using-two-or-more-sessions-within-one-XA-Transaction-tp4661376.html
Sent from the Jackrabbit - Users mailing list archive at Nabble.com.

Thomas Auinger | 11 Sep 10:46 2014
Picon

Performance of DefaultISMLocking.releaseReadLock()

Hello,

I am currently profiling a single-threaded Jackrabbit 2.8 application, which is reading 1800 nodes into
POJOs (we store entity data in JCR).

VisualVM sampling tells me, that 57% of all time is spend in method org.apache.jackrabbit.core.state.DefaultISMLocking.releaseReadLock()

Now while that method does not look very complicated, I was wondering if there are known tips how to speed up
locking (wiki page says its "TODO") or if anybody has helpful thoughts on this.

Thanks in advance

Tom
Tom Barber | 8 Sep 11:34 2014

Webdav server set mixin on new nodes

Hi guys

I've setup a repository and then got a requirement later to add webdav 
access. My repo contains a bunch of different file types some of which I 
apply mixins to to help me find files, set extra information etc.

So when someone creates a new node via webdav, if I can detect the file 
type using Tika or something can I then apply the mixin the a new node?

Thanks

Tom
--

-- 
*Tom Barber* | Technical Director

meteorite bi
*T:* +44 20 8133 3730
*W:* www.meteorite.bi | *Skype:* meteorite.consulting
*A:* Surrey Technology Centre, Surrey Research Park, Guildford, GU2 7YG, UK
ke8 | 7 Sep 15:18 2014
Picon

JCR performance

Hello, 
I need advice how to improve JCR(2.4.1) performance. My solution need to
store more than 10 000 000 xml documents. I have available more than 10 GB
of RAM. Repository is accessed over RMI. I found only instructions, that
it’s good to increase memory to persistence manager and not having to many
child on a single node (in my solution one node can have max. 4096 child). I
need to accelerate insert and update mainly. Could anyone please advise me
how can I adjust configuration to improve performance? Thank you very much
for your answers. Sorry for my English…

wokspace.xml :

<?xml version="1.0" encoding="UTF-8"?><Workspace name="default">

        <FileSystem
class="org.apache.jackrabbit.core.fs.local.LocalFileSystem">
            <param name="path" value="${wsp.home}"/>
        </FileSystem>

        <PersistenceManager
class="org.apache.jackrabbit.core.persistence.pool.DerbyPersistenceManager">
          <param name="url"
value="jdbc:derby:${wsp.home}/db;create=true"/>
          <param name="schemaObjectPrefix" value="${wsp.name}_"/>
		  <param name="externalBLOBs" value="true"/>
          <param name="consistencyCheck" value="false"/>
          <param name="consistencyFix" value="false"/>
          <param name="bundleCacheSize" value="4096" />  
        </PersistenceManager>

(Continue reading)

uv | 3 Sep 11:45 2014
Picon

How to clean huge datastore?

Hi,

our system uses jackrabbit 2.6.5 and MySQL DB datastore. Jackrabbit DB
schema size is 300GB, most of it is in datastore. When we run jackrabbit
garbage collector, it runs almost 3 days. Running GC has significant impact
on application performance.

Could you please advice what possibility we have?

Somehow spit GC to do not iterate through whole datastore? When GC is not
finished completely, we can not run datastore clean because we can not be
sure what has been scanned and what has not.

Or is there any other GC implementation?

Thank you very much.

Vlastimil

--
View this message in context: http://jackrabbit.510166.n4.nabble.com/How-to-clean-huge-datastore-tp4661356.html
Sent from the Jackrabbit - Users mailing list archive at Nabble.com.

techie2k | 3 Sep 08:56 2014
Picon

Creating empty string for 'rep:glob'

To restrict node access to user(using principalbased acl), tried with
following snippet, but turns ineffective.

/Map<String, Value> restrictions = new HashMap<String, Value>();
//Apply privilege to user to have read only access to root folder
restrictions.put("rep:nodePath", valueFactory.createValue(ROOT,
PropertyType.PATH));
restrictions.put("rep:glob", valueFactory.createValue(""));
accessControlList.addEntry(userPrincipal, privileges, true  , restrictions);
accessControlManager.setPolicy(accessControlList.getPath(),
accessControlList);/

Is there any other way to set 'rep:glob' property to ""?

--
View this message in context: http://jackrabbit.510166.n4.nabble.com/Creating-empty-string-for-rep-glob-tp4661354.html
Sent from the Jackrabbit - Users mailing list archive at Nabble.com.

Andrew Savory | 2 Sep 17:07 2014
Picon

[Event] User and developer meetup in Berlin

Hi,

On 22-24 Sept there will be the adaptTo() event in Berlin. This event is
for users and developers of Apache Jackrabbit, as well as Sling, Felix,
Cordova, Solr, etc (and many other technologies that go into Adobe's AEM
platform).

You can find more information at http://adapt.to/2014/en.html and you can
register at http://adapt.to/2014/en/tickets.html

It's a great event with lots of opportunity for technical discussions, and
includes a mini hackathon on day 2.

Hope to see you there!

Thanks,

Andrew.
--
asavory <at> apache.org / contact <at> andrewsavory.com
http://www.andrewsavory.com/
Mathijs den Burger | 2 Sep 09:35 2014

Syncing a local directory using FileVault

Hi,

I'm trying to use FileVault to automatically sync a local directory
from filesystem into a Hippo repository (which is based on
JackRabbit). The main reason for using FileVault is the automatic
handling of meta-data in the .content.xml files.

So far I've successfully used the Importer class to import an Archive
based on files or a zip file. I've also implemented a simple file
watcher that triggers a reimport whenever something changes. This
nicely imports changes and newly added files and directories. So far
so good.

The problem is that deleting files or directories does not delete
their counterparts in JCR. I'd expect that using ImportMode.REPLACE
would completely replace the JCR node structure and automatically
delete everything that is no longer present in the imported archive,
but that's not the case.

Reading through code it seems the vlt tool uses the meta-data in the
.vlt directory to track deleted files, which are then processed during
a commit. Is there a way to add such meta-data to an Archive or
educate the Importer somehow?

I've also read through the code of the vault-sync tool, which
basically implements my use case. I cannot use it as-is though, since
Hippo does not use OSGI. IIUC vault-sync does not use Archives or
Packages at all, but uses its own TreeSync class that does lots of
plain JCR calls. Does that mean that vault-sync does not process
meta-data files at all?
(Continue reading)

Thomas Mueller | 1 Sep 10:32 2014
Picon

[ANNOUNCE] Apache Jackrabbit Oak 1.0.5 released

The Apache Jackrabbit community is pleased to announce the release of
Apache Jackrabbit Oak 1.0.5. The release is available for download at:

    http://jackrabbit.apache.org/downloads.html

See the full release notes below for details about this release.

Release Notes -- Apache Jackrabbit Oak -- Version 1.0.5

Introduction
------------

Jackrabbit Oak is a scalable, high-performance hierarchical content
repository designed for use as the foundation of modern world-class
web sites and other demanding content applications.

Apache Jackrabbit Oak 1.0.5 is a patch release that contains fixes and
improvements over Oak 1.0. Jackrabbit Oak 1.0.x releases are considered
stable and targeted for production use.

The Oak effort is a part of the Apache Jackrabbit project.
Apache Jackrabbit is a project of the Apache Software Foundation.

Changes in Oak 1.0.5
--------------------

Bug fixes

  [OAK-2020] - NodeState view at given version is not stable with
DocumentNodeStore
(Continue reading)

Thomas Zastrow | 30 Aug 14:34 2014
Picon

Depricated methods in documentation

Dear all,

I'm fairly new to Jackrabbit and tried to find my way through the 
documentation. On the page about Node Types 
(http://jackrabbit.apache.org/node-types.html), there is example code 
which utilizes

org.apache.jackrabbit.api.JackrabbitNodeTypeManager

But that class seems to be marked as deprecated? Is there any newer 
documentation?

Thanks and best wishes,

Tom

--

-- 
Dr. Thomas Zastrow
Riemerfeldring 7a

85748 Garching bei München
www.thomas-zastrow.de


Gmane