Hello Remy,
I just found out one implication of not deleting the revisions:
If only the structure is deleted, the child store "content" is not informed
about the delete. Therefore the content object persists, but the logical
part (node) is removed. If the object is re-created the content object is
located twice in the persistent store.
If the resource is not revisioned, I believe it would be OK to remove it
completely. This keeps the persistent store smaller. Possibly we could have
a flag (in domain.xml?) to specify if the delete is persistent, or the
content can be recreated.
If the resource is revisioned, I believe we should have two methods to
delete. One deletes the revision permanently, the other deletes it logically
only. I have not read the Delta-V standard in detail, does someone know if
this behavior is part of the standard.
What do you think?
PS. Lately I was searching for following problem: create, lock, delete,
create a resource. If the resource was locked again an error message was
produced, resource already locked. I believe now, this has something to do
with deleting the nodes only.
Best regards
Juergen Pill
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Thursday, February 08, 2001 8:23 PM
To: [EMAIL PROTECTED]
Subject: cvs commit: jakarta-slide/src/share/org/apache/slide/macro
MacroImpl.java
remm 01/02/08 11:22:46
Modified: src/share/org/apache/slide/macro MacroImpl.java
Log:
- Will not attempt to delete any revision. Only the struture will be
modified by
delete. This is the correct behavior IMO, because :
- If there is nothing in the structure, then the object is considered to
not exist.
- The object along with all its revisions can be resurrected by
recreating
it in the structure. This is very similar to CVS.
Revision Changes Path
1.8 +4 -14
jakarta-slide/src/share/org/apache/slide/macro/MacroImpl.java
Index: MacroImpl.java
===================================================================
RCS file:
/home/cvs/jakarta-slide/src/share/org/apache/slide/macro/MacroImpl.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- MacroImpl.java 2001/02/01 23:19:12 1.7
+++ MacroImpl.java 2001/02/08 19:22:32 1.8
@@ -1,7 +1,7 @@
/*
- * $Header:
/home/cvs/jakarta-slide/src/share/org/apache/slide/macro/MacroImpl.java,v
1.7 2001/02/01 23:19:12 remm Exp $
- * $Revision: 1.7 $
- * $Date: 2001/02/01 23:19:12 $
+ * $Header:
/home/cvs/jakarta-slide/src/share/org/apache/slide/macro/MacroImpl.java,v
1.8 2001/02/08 19:22:32 remm Exp $
+ * $Revision: 1.8 $
+ * $Date: 2001/02/08 19:22:32 $
*
* ====================================================================
*
@@ -76,7 +76,7 @@
* Macro helper class.
*
* @author <a href="mailto:[EMAIL PROTECTED]">Remy Maucherat</a>
- * @version $Revision: 1.7 $
+ * @version $Revision: 1.8 $
*/
public final class MacroImpl implements Macro {
@@ -414,16 +414,6 @@
deleteObject(token, (String) children.nextElement(),
e);
}
- }
-
- // Removing all revisions
- NodeRevisionDescriptors revisionDescriptors =
- contentHelper.retrieve(token, targetUri);
-
- // For now, only delete the initial revision
- if (revisionDescriptors.hasRevisions()) {
- contentHelper.remove(token, targetUri,
-
revisionDescriptors.getInitialRevision());
}
// Removing object