You are viewing a plain text version of this content. The canonical link for it is here.
Posted to slide-user@jakarta.apache.org by Hannes Ebner <de...@stdout.at> on 2006/09/19 20:20:11 UTC

Versioning

Hi

I have a few questions to versioning (WebDAV on top of Subversion with
Apache 2 and mod_dav).

1) I cannot get checkin and checkout working properly, read access (GET)
works.

Here is some sample code:

HttpURL url = new HttpURL("http://localhost/test/test.txt"); //this file
exists
res = new WebdavResource(url, true); // returns 200 OK
res.checkoutMethod(url.getPath()); // returns 405 Method not allowed
res.putMethod(url.getPath(), "***Contents***"); // returns 409 Conflict
res.checkinMethod(url.getPath()); // returns 409 Conflict

Is there some sample code available of how a file modification in the
repository should look like? I don't want to change the configuration
(auto-versioning or something like that, in order to get rid of the
checkout/checkin) on the client side, as this would make the deployment
difficult.

Authentication is turned off. Checkin and checkout works from the
command line under Linux.

2) I want to get the current revision number of a checked-in file. Is
the only possibility to make a PROPFIND for "DAV:version-name"?

3) Can "DAV:version-name" also contain something else than the number of
a Subversion revision (Integer)? A String for example?

3) How do I find out whether a resource is versioned? Check whether the
properties "DAV:version-name" or "DAV:checked-in" are set?

4) I want to retrieve an "old" revision. What is the official way of
doing this? I know that I can get a specific revision through pointing
the HttpURL object to e.g. "http://localhost/!svn/ver/3/test" (to get
revision 3 of "http://localhost/test"), but this seems to be a bit long
winded (and "DAV:checked-in" does not exist by accessing the node this
way). Is there a better way of doing this?

5) The properties "DAV:creationdate" and "DAV:getlastmodified" are
returned in different date formats. Why?

6) Is there some detailed documentation (perhaps with some sample code)
on how to use the versioning capabilities of Slide?

Would be great if I got a few questions answered, thanks in advance!

Best regards,
Hannes

---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org


Re: Versioning

Posted by Hannes Ebner <de...@stdout.at>.
Hannes Ebner wrote:
> With which RCS does check[in|out]Method() work? Or in other words: How
> do I update, add or delete files in a versioned repository (preferably
> Subversion)?
> 
> Do you have an idea what I can do to use Slide with WebDAV/Subversion?

I don't know why it doesn't work with checkout/put/checkin, I also tried
an mkworkspace before. Somebody else who tried Slide with mod_dav_svn?

I enabled now autoversioning on server-side, following this page:
<http://svnbook.red-bean.com/nightly/en/svn.webdav.autoversioning.html>.

It works, but I'm not really happy with it as I would like to have more
control over revisions (like I would have with a manual checkout/...).

Best regards,
Hannes

---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org


Re: Versioning

Posted by Hannes Ebner <de...@stdout.at>.
Julian Reschke wrote:
>> 1) I cannot get checkin and checkout working properly, read access (GET)
>> works.
> 
> I don't believe that Subversion supports checkout-in-place.

With which RCS does check[in|out]Method() work? Or in other words: How
do I update, add or delete files in a versioned repository (preferably
Subversion)?

Do you have an idea what I can do to use Slide with WebDAV/Subversion?

>> 4) I want to retrieve an "old" revision. What is the official way of
>> doing this? I know that I can get a specific revision through pointing
>> the HttpURL object to e.g. "http://localhost/!svn/ver/3/test" (to get
>> revision 3 of "http://localhost/test"), but this seems to be a bit long
>> winded (and "DAV:checked-in" does not exist by accessing the node this
>> way). Is there a better way of doing this?
> 
> Well, there are multiple ways to do that. Check RFC3253.

Ok. I just wanted to make sure that I didn't miss a Slide-specific
method for accessing revisions. A thing like getMethod(String path,
String version-name) would be pretty handy.

Best regards,
Hannes

---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org


Re: Versioning

Posted by Julian Reschke <ju...@gmx.de>.
Hannes Ebner schrieb:
> Hi
> 
> I have a few questions to versioning (WebDAV on top of Subversion with
> Apache 2 and mod_dav).
> 
> 1) I cannot get checkin and checkout working properly, read access (GET)
> works.

I don't believe that Subversion supports checkout-in-place.

> Here is some sample code:
> 
> HttpURL url = new HttpURL("http://localhost/test/test.txt"); //this file
> exists
> res = new WebdavResource(url, true); // returns 200 OK
> res.checkoutMethod(url.getPath()); // returns 405 Method not allowed
> res.putMethod(url.getPath(), "***Contents***"); // returns 409 Conflict
> res.checkinMethod(url.getPath()); // returns 409 Conflict
> 
> Is there some sample code available of how a file modification in the
> repository should look like? I don't want to change the configuration
> (auto-versioning or something like that, in order to get rid of the
> checkout/checkin) on the client side, as this would make the deployment
> difficult.
> 
> Authentication is turned off. Checkin and checkout works from the
> command line under Linux.
> 
> 2) I want to get the current revision number of a checked-in file. Is
> the only possibility to make a PROPFIND for "DAV:version-name"?

...on the version. Yes, I think so.

> 3) Can "DAV:version-name" also contain something else than the number of
> a Subversion revision (Integer)? A String for example?

Yes (in general).

> 3) How do I find out whether a resource is versioned? Check whether the
> properties "DAV:version-name" or "DAV:checked-in" are set?

It's version controlled if either checked-in or checked-out is set.

> 4) I want to retrieve an "old" revision. What is the official way of
> doing this? I know that I can get a specific revision through pointing
> the HttpURL object to e.g. "http://localhost/!svn/ver/3/test" (to get
> revision 3 of "http://localhost/test"), but this seems to be a bit long
> winded (and "DAV:checked-in" does not exist by accessing the node this
> way). Is there a better way of doing this?

Well, there are multiple ways to do that. Check RFC3253.

> 5) The properties "DAV:creationdate" and "DAV:getlastmodified" are
> returned in different date formats. Why?

Historic. DAV:getlastmodified is defined based on the HTTP last-modified 
header.

> 6) Is there some detailed documentation (perhaps with some sample code)
> on how to use the versioning capabilities of Slide?

Dunno.

> Would be great if I got a few questions answered, thanks in advance!

Best regards, Julian

---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org