jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Thomas Mueller (JIRA)" <j...@apache.org>
Subject [jira] Commented: (JCR-2049) A tool to support large or long running transactions
Date Tue, 17 Nov 2009 16:49:39 GMT

    [ https://issues.apache.org/jira/browse/JCR-2049?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12778987#action_12778987
] 

Thomas Mueller commented on JCR-2049:
-------------------------------------

The use case for this tool is "long running" transactions, 
which is a bit different than just "large" transactions:
http://en.wikipedia.org/wiki/Long-running_transaction

But in addition to support long running transactions,
this tool would also support large transactions.

> A tool to support large or long running transactions
> ----------------------------------------------------
>
>                 Key: JCR-2049
>                 URL: https://issues.apache.org/jira/browse/JCR-2049
>             Project: Jackrabbit Content Repository
>          Issue Type: New Feature
>          Components: jackrabbit-jcr-commons
>            Reporter: Thomas Mueller
>            Assignee: Thomas Mueller
>            Priority: Minor
>
> I propose to write a tool for large or long running transactions. Instead of keeping
the changes in the transient space until a transaction is completed, a backup of the current
state is stored in a backup area. This allows to save intermediate steps.
> I propose to create add a tool (probably just one class) in the jackrabbit-jcr-commons
project, package org.apache.jackrabbit.commons.tools:
> class LargeTransactionTool {
>   LargeTransactionTool getInstance(Session session, String backupPath);
>   beginTransaction();
>   deleteRecursive(Node n);
>   Node addNode(Node parent, String name);
>   backup(Node n);
>   backupRecursive(Node n);
>   commit();
>   rollback();
> }
> An application could then use the tool as follows:
> LargeTransactionTool tool = LargeTransactionTool.getInstance(session, "/backupArea");
> tool.backup(n1);
> n1.setProperty(...);
> session.save();
> tool.deleteRecursive(n2);
> session.save();
> n4 = tool.addNode(n3, "x");
> session.save();
> tool.commit();

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message