Interesting. Ok, I'll check it out. Thanks! On Fri, Dec 4, 2009 at 7:49 AM, Bertrand Delacretaz <[email protected]>wrote:
> Hi, > > On Fri, Dec 4, 2009 at 6:53 AM, John Crawford <[email protected]> wrote: > > ...I was wondering if you all had ever performed a zip file upload and > > unpacked it within the repo? (Is there already an API and set of best > > practices for this?)... > > The best is to use a JCR observer to detect the incoming zip file, and > when it's complete you can get an InputStream of its data via the JCR > API, and unpack the archive. > > The espblog's sample ThumbnailGenerator service uses a similar > mechanism to generate thumbnails for uploaded images. > > -Bertrand > > [1] > http://svn.apache.org/repos/asf/sling/trunk/samples/espblog/src/main/java/org/apache/sling/samples/espblog/internal/ThumbnailGenerator.java >
