How to store randomly accessed files (both on writing and reading) in Jackrabbit JCR implementation?

StackOverflow https://stackoverflow.com/questions/2341640

  •  22-09-2019
  •  | 
  •  

Question

Is it possible to store randomly accessed files (both on writing and reading) in Jackrabbit JCR implementation, if documentation says that DataStore interface stores data immutable.

Was it helpful?

Solution

Within the JCR API, random access within a binary is not supported. The only workaround is to use InputStream.seek (but you can only seek forward). Of course you can create a temporary table and use RandomAccessFile on that (or for small binaries edit them in-memory), but you probably already know that.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top