[xwiki-devs] SVN Application for XWiki
Hi, If you are following the xwiki comments, you might have seen that I've been working on an SVN application for XWiki. I've published this application here: http://code.xwiki.org/xwiki/bin/view/Applications/SVNApplication The objective of this application is to bring to XWiki Applications more professional development practices. One of them is the ability to do version management of XWiki applications. Of course XWiki contains versioning but this versioning does not apply accross wikis and makes it difficult to contribute code back to the community. With the SVN application you can now directly contribute code and code updates to the XWiki SVN contrib repository or to any other SVN repository. You can even commit in multiple SVN repositories in the same Wiki. The SVN Application supports: 1/ Compare the Wiki (limited to a list of spaces) with the SVN repository listing - added pages in the wiki - modified pages in the wiki - new pages in SVN - modified pages in SVN - conflicting pages modified in both SVN and the Wiki 2/ Commit in the SVN Repository 3/ Update from the SVN Repostory 4/ Show differences between SVN and the Wiki (in XML) The SVN Application does not provide merging and conflict resolution. The SVN Application normalizes XWiki XML allowing the cleanup the XML to not have the user, the dates, comments. This is necessary to provide concurrent development on multiple XWiki server without telling you that the pages have changed all the time. The source code is of course in SVN at http://svn.xwiki.org/svnroot/xwiki/contrib/sandbox/xwiki-svn/ Ludovic -- Ludovic Dubost Blog: http://blog.ludovic.org/ XWiki: http://www.xwiki.com Skype: ldubost GTalk: ldubost
Ludovic, this sounds like a greeeeat addition but let me get more details: - in what forms are the pages committed? In xwiki-document-xml? Without an external source linking for the body of the content? (e.g. an entity definition using the relative file xxx.vm when it's obviously a velocity source?). - Is there a place where I can see it in action? thanks in advance paul Le 22-avr.-10 à 19:42, Ludovic Dubost a écrit :
Hi,
If you are following the xwiki comments, you might have seen that I've been working on an SVN application for XWiki.
I've published this application here: http://code.xwiki.org/xwiki/bin/view/Applications/SVNApplication
The objective of this application is to bring to XWiki Applications more professional development practices. One of them is the ability to do version management of XWiki applications. Of course XWiki contains versioning but this versioning does not apply accross wikis and makes it difficult to contribute code back to the community.
With the SVN application you can now directly contribute code and code updates to the XWiki SVN contrib repository or to any other SVN repository. You can even commit in multiple SVN repositories in the same Wiki.
The SVN Application supports:
1/ Compare the Wiki (limited to a list of spaces) with the SVN repository listing - added pages in the wiki - modified pages in the wiki - new pages in SVN - modified pages in SVN - conflicting pages modified in both SVN and the Wiki 2/ Commit in the SVN Repository 3/ Update from the SVN Repostory 4/ Show differences between SVN and the Wiki (in XML)
The SVN Application does not provide merging and conflict resolution. The SVN Application normalizes XWiki XML allowing the cleanup the XML to not have the user, the dates, comments. This is necessary to provide concurrent development on multiple XWiki server without telling you that the pages have changed all the time.
The source code is of course in SVN at http://svn.xwiki.org/svnroot/xwiki/contrib/sandbox/xwiki-svn/
Ludovic
-- Ludovic Dubost Blog: http://blog.ludovic.org/ XWiki: http://www.xwiki.com Skype: ldubost GTalk: ldubost
<ludovic.vcf>_______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
Hi, Le 22/04/10 23:13, Paul Libbrecht a écrit :
Ludovic,
this sounds like a greeeeat addition but let me get more details:
- in what forms are the pages committed? In xwiki-document-xml? Without an external source linking for the body of the content? (e.g. an entity definition using the relative file xxx.vm when it's obviously a velocity source?).
XWiki xml at this point including attachments and content. No the body of the content is not extracted.. To do so we would need an xwiki xar plugin that can rebuild the xar from an extracted source, as we want to be able to generate a xar with maven also
- Is there a place where I can see it in action?
No because this would let people commit stuff Ludovic
thanks in advance
paul
Le 22-avr.-10 à 19:42, Ludovic Dubost a écrit :
Hi,
If you are following the xwiki comments, you might have seen that I've been working on an SVN application for XWiki.
I've published this application here: http://code.xwiki.org/xwiki/bin/view/Applications/SVNApplication
The objective of this application is to bring to XWiki Applications more professional development practices. One of them is the ability to do version management of XWiki applications. Of course XWiki contains versioning but this versioning does not apply accross wikis and makes it difficult to contribute code back to the community.
With the SVN application you can now directly contribute code and code updates to the XWiki SVN contrib repository or to any other SVN repository. You can even commit in multiple SVN repositories in the same Wiki.
The SVN Application supports:
1/ Compare the Wiki (limited to a list of spaces) with the SVN repository listing - added pages in the wiki - modified pages in the wiki - new pages in SVN - modified pages in SVN - conflicting pages modified in both SVN and the Wiki 2/ Commit in the SVN Repository 3/ Update from the SVN Repostory 4/ Show differences between SVN and the Wiki (in XML)
The SVN Application does not provide merging and conflict resolution. The SVN Application normalizes XWiki XML allowing the cleanup the XML to not have the user, the dates, comments. This is necessary to provide concurrent development on multiple XWiki server without telling you that the pages have changed all the time.
The source code is of course in SVN at http://svn.xwiki.org/svnroot/xwiki/contrib/sandbox/xwiki-svn/
Ludovic
-- Ludovic Dubost Blog: http://blog.ludovic.org/ XWiki: http://www.xwiki.com Skype: ldubost GTalk: ldubost
<ludovic.vcf>_______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
_______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
-- Ludovic Dubost Blog: http://blog.ludovic.org/ XWiki: http://www.xwiki.com Skype: ldubost GTalk: ldubost
Hi,
Le 22/04/10 23:13, Paul Libbrecht a écrit :
Ludovic,
this sounds like a greeeeat addition but let me get more details:
- in what forms are the pages committed? In xwiki-document-xml? Without an external source linking for the body of the content? (e.g. an entity definition using the relative file xxx.vm when it's obviously a velocity source?).
XWiki xml at this point including attachments and content. No the body of the content is not extracted.. To do so we would need an xwiki xar plugin that can rebuild the xar from an extracted source, as we want to be able to generate a xar with maven also
+ now most (ideally all) documents have xwiki/2.0 syntax content, which is not HTML/velocity mix, so extracting the content has a bit less value - until there are more tools around xwiki 2.0 syntax, that is :) It would mostly provide nicer, not XML-encoded, diffs The maven plugin to inject the content from an external source is not very hard to do, we just have to define some conventions/ default configuration (for example it could be : if there is a file named MyDoc.xwiki20 or MyDoc.vm then its content is injected when loading MyDoc.xml) Very useful app already, anyway. Jerome
- Is there a place where I can see it in action?
No because this would let people commit stuff
Ludovic
thanks in advance
paul
Le 22-avr.-10 à 19:42, Ludovic Dubost a écrit :
Hi,
If you are following the xwiki comments, you might have seen that I've been working on an SVN application for XWiki.
I've published this application here: http://code.xwiki.org/xwiki/bin/view/Applications/SVNApplication
The objective of this application is to bring to XWiki Applications more professional development practices. One of them is the ability to do version management of XWiki applications. Of course XWiki contains versioning but this versioning does not apply accross wikis and makes it difficult to contribute code back to the community.
With the SVN application you can now directly contribute code and code updates to the XWiki SVN contrib repository or to any other SVN repository. You can even commit in multiple SVN repositories in the same Wiki.
The SVN Application supports:
1/ Compare the Wiki (limited to a list of spaces) with the SVN repository listing - added pages in the wiki - modified pages in the wiki - new pages in SVN - modified pages in SVN - conflicting pages modified in both SVN and the Wiki 2/ Commit in the SVN Repository 3/ Update from the SVN Repostory 4/ Show differences between SVN and the Wiki (in XML)
The SVN Application does not provide merging and conflict resolution. The SVN Application normalizes XWiki XML allowing the cleanup the XML to not have the user, the dates, comments. This is necessary to provide concurrent development on multiple XWiki server without telling you that the pages have changed all the time.
The source code is of course in SVN at http://svn.xwiki.org/svnroot/xwiki/contrib/sandbox/xwiki-svn/
Ludovic
-- Ludovic Dubost Blog: http://blog.ludovic.org/ XWiki: http://www.xwiki.com Skype: ldubost GTalk: ldubost
<ludovic.vcf>_______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
_______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
-- Ludovic Dubost Blog: http://blog.ludovic.org/ XWiki: http://www.xwiki.com Skype: ldubost GTalk: ldubost _______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
Hi Ludovic, I have made some quick testing of this application in our sandbox, and I have discovered weird issues in relation with the document history. Here is what I have noticed so far: - Checking out new document from the repository, the document does not have an history at all, and the creator of the document is not set - Checking out a existing document from the repository (reverting a change), cause the history of the document to be somewhat inverted, the current document being 1.1 version and the history containing later versions... (except when only 1.1 version were existing). The document also cause an exception when you try to save some modification to it: Detailed information: Error number 3201 in 3: Exception while saving document Main.TestPage2 Wrapped Exception: Failed to commit or rollback transaction. Root cause [] com.xpn.xwiki.XWikiException: Error number 3201 in 3: Exception while saving document Main.TestPage2 Wrapped Exception: Failed to commit or rollback transaction. Root cause [] at com.xpn.xwiki.store.XWikiHibernateStore.saveXWikiDoc(XWikiHibernateStore.java:638) ... Wrapped Exception: org.hibernate.StaleStateException: Batch update returned unexpected row count from update [1]; actual row count: 0; expected: 1 The change is then recorded in the archive and not in the document, creating the same "inverted" history situation. I suspect it happen due to a discrepancy between the cache and the database, since after a restart, the 1.1 (current) version is no more in the history. - After a restart, I also got some "C" status, which are not documented, and I imagine, means conflict. But since this is just a restart that cause them, this not expected. Looking at the details, this append on groups, because of object GUID changes without any other changes, and it may be unrelated to your application in particular. - At an initial attempt to go back to the list after committing and then updating a new page, it has shown a status of '?' in place of 'M', but I have not reproduced that later :( - SVN operations also cause the recycle bin to contains deleted document, is it intended ? I also have a question regarding the usage of the status field. Why it is required to keep this status ? if needed, why coding it in place of keeping it with each document (in an xobject) ? Denis On Thu, Apr 22, 2010 at 19:42, Ludovic Dubost <[email protected]> wrote:
Hi,
If you are following the xwiki comments, you might have seen that I've been working on an SVN application for XWiki.
I've published this application here: http://code.xwiki.org/xwiki/bin/view/Applications/SVNApplication
The objective of this application is to bring to XWiki Applications more professional development practices. One of them is the ability to do version management of XWiki applications. Of course XWiki contains versioning but this versioning does not apply accross wikis and makes it difficult to contribute code back to the community.
With the SVN application you can now directly contribute code and code updates to the XWiki SVN contrib repository or to any other SVN repository. You can even commit in multiple SVN repositories in the same Wiki.
The SVN Application supports:
1/ Compare the Wiki (limited to a list of spaces) with the SVN repository listing - added pages in the wiki - modified pages in the wiki - new pages in SVN - modified pages in SVN - conflicting pages modified in both SVN and the Wiki 2/ Commit in the SVN Repository 3/ Update from the SVN Repostory 4/ Show differences between SVN and the Wiki (in XML)
The SVN Application does not provide merging and conflict resolution. The SVN Application normalizes XWiki XML allowing the cleanup the XML to not have the user, the dates, comments. This is necessary to provide concurrent development on multiple XWiki server without telling you that the pages have changed all the time.
The source code is of course in SVN at http://svn.xwiki.org/svnroot/xwiki/contrib/sandbox/xwiki-svn/
Ludovic
-- Ludovic Dubost Blog: http://blog.ludovic.org/ XWiki: http://www.xwiki.com Skype: ldubost GTalk: ldubost
_______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
-- Denis Gervalle SOFTEC sa - CEO eGuilde sarl - CTO
Hi Denis, Thanks for the feedback and testing Le 03/05/10 21:20, Denis Gervalle a écrit :
Hi Ludovic,
I have made some quick testing of this application in our sandbox, and I have discovered weird issues in relation with the document history.
Here is what I have noticed so far:
I've seen indeed some issue with the history. I thought it was limited to having to resave the document to fix it. I will look into it. I had to add some code specially for handling attachments. I suspect that is what is creating the problems
- Checking out new document from the repository, the document does not have an history at all, and the creator of the document is not set - Checking out a existing document from the repository (reverting a change), cause the history of the document to be somewhat inverted, the current document being 1.1 version and the history containing later versions... (except when only 1.1 version were existing). The document also cause an exception when you try to save some modification to it:
Detailed information: Error number 3201 in 3: Exception while saving document Main.TestPage2 Wrapped Exception: Failed to commit or rollback transaction. Root cause [] com.xpn.xwiki.XWikiException: Error number 3201 in 3: Exception while saving document Main.TestPage2 Wrapped Exception: Failed to commit or rollback transaction. Root cause [] at com.xpn.xwiki.store.XWikiHibernateStore.saveXWikiDoc(XWikiHibernateStore.java:638) ... Wrapped Exception: org.hibernate.StaleStateException: Batch update returned unexpected row count from update [1]; actual row count: 0; expected: 1
The change is then recorded in the archive and not in the document, creating the same "inverted" history situation. I suspect it happen due to a discrepancy between the cache and the database, since after a restart, the 1.1 (current) version is no more in the history.
- After a restart, I also got some "C" status, which are not documented, and I imagine, means conflict. But since this is just a restart that cause them, this not expected. Looking at the details, this append on groups, because of object GUID changes without any other changes, and it may be unrelated to your application in particular. Interesting. How come would GUID change in groups ? Indeed this does not seem related to the SVN app. Either this is normal and then we could change the comparaison to ignore such GUID changes. However the GUID is important data.
- At an initial attempt to go back to the list after committing and then updating a new page, it has shown a status of '?' in place of 'M', but I have not reproduced that later :( The only reason to show ? is that either
there is a change both in SVN and in the Wiki OR the status information is not filled in
- SVN operations also cause the recycle bin to contains deleted document, is it intended ? This is possible.. I have to check
I also have a question regarding the usage of the status field. Why it is required to keep this status ? if needed, why coding it in place of keeping it with each document (in an xobject) ?
I thought about that but did not want the SVN application to have any impact on the wiki you want to commit to SVN Ludovic
Denis
On Thu, Apr 22, 2010 at 19:42, Ludovic Dubost<[email protected]> wrote:
Hi,
If you are following the xwiki comments, you might have seen that I've been working on an SVN application for XWiki.
I've published this application here: http://code.xwiki.org/xwiki/bin/view/Applications/SVNApplication
The objective of this application is to bring to XWiki Applications more professional development practices. One of them is the ability to do version management of XWiki applications. Of course XWiki contains versioning but this versioning does not apply accross wikis and makes it difficult to contribute code back to the community.
With the SVN application you can now directly contribute code and code updates to the XWiki SVN contrib repository or to any other SVN repository. You can even commit in multiple SVN repositories in the same Wiki.
The SVN Application supports:
1/ Compare the Wiki (limited to a list of spaces) with the SVN repository listing - added pages in the wiki - modified pages in the wiki - new pages in SVN - modified pages in SVN - conflicting pages modified in both SVN and the Wiki 2/ Commit in the SVN Repository 3/ Update from the SVN Repostory 4/ Show differences between SVN and the Wiki (in XML)
The SVN Application does not provide merging and conflict resolution. The SVN Application normalizes XWiki XML allowing the cleanup the XML to not have the user, the dates, comments. This is necessary to provide concurrent development on multiple XWiki server without telling you that the pages have changed all the time.
The source code is of course in SVN at http://svn.xwiki.org/svnroot/xwiki/contrib/sandbox/xwiki-svn/
Ludovic
-- Ludovic Dubost Blog: http://blog.ludovic.org/ XWiki: http://www.xwiki.com Skype: ldubost GTalk: ldubost
_______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
-- Ludovic Dubost Blog: http://blog.ludovic.org/ XWiki: http://www.xwiki.com Skype: ldubost GTalk: ldubost -- Ludovic Dubost Blog: http://blog.ludovic.org/ XWiki: http://www.xwiki.com Skype: ldubost GTalk: ldubost
participants (4)
-
Denis Gervalle -
Jerome Velociter -
Ludovic Dubost -
Paul Libbrecht