0
votes

I am looking for an alternative to JackRabbit SimpleWebdavServer (but still connected to JackRabbit repo).

We have JackRabbit exposed via SimpleWebdavServer. Users can edit doc/docx files stored in repository. Problem is with versioned (checked in) files - JackRabbit apparently does not support auto-checkout/checkin and I am not able to tell MS Word to do checkout/ckeckin. So I am looking for WebDav server implementation that is able do checkout/checkin automatically.

1

1 Answers

0
votes

You could look at Milton. Its a purpose built webdav server framework which allows you to abstract access to any data store such as Jackrabbit. Milton supports Dav level 2 (ie locking) and is compatible with all major clients and operating systems. Milton doesnt provide the UI but there are examples showing how to open documents.

Here is a an example implementation:

@Get
public InputStream getImageFile(Image image) throws IOException {
    return MyImageUtils.openInputStream(content);                       
}

@PutChild
public Image uploadImage(Image image, byte[] bytes, ImagesRoot root) throws IOException {
    MyImageUtils.writeByteArrayToFile(image, bytes);
    return image;
}   

There is a bit more to it, you also need methods to locate resources and provide metadata like uniqueID, modified date, etc.

Here's the hello world controller: https://github.com/miltonio/milton2/blob/master/examples/tuts-anno1/src/main/java/com/helloworld/HelloWorldController.java