Last modified by Thomas Mortagne on 2023/10/13

<
From version < 15.1 >
edited by Marius Dumitru Florea
on 2011/02/08
To version < 17.1 >
edited by Caleb James DeLisle
on 2011/02/10
>
Change comment: attachment storage

Summary

Details

Page properties
Author
... ... @@ -1,1 +1,1 @@
1 -XWiki.mflorea
1 +XWiki.Caleb_James_DeLisle
Content
... ... @@ -44,6 +44,7 @@
44 44  * [[XWIKI-5918>>http://jira.xwiki.org/jira/browse/XWIKI-]]: Impossible to override XSLT documents used in the PDF export process
45 45  * [[XWIKI-5923>>http://jira.xwiki.org/jira/browse/XWIKI-5923]]: Page names containing [ or ] break the REST search results
46 46  * [[XWIKI-4802>>http://jira.xwiki.org/jira/browse/XWIKI-4802]]: Add MetaData Block/Events to allow specifying meta data to XDOM/Listeners
47 +* [[XWIKI-5942>>http://jira.xwiki.org/jira/browse/XWIKI-5942]]: Introduce new filesystem based attachment storage
47 47  * [[XSKINX-42>>http://jira.xwiki.org/jira/browse/XSKINX-42]]: Deleting an SSX objects from a document prevents skin objects to be used on demand in that document
48 48  * [[XAADMINISTRATION-212>>http://jira.xwiki.org/jira/browse/XAADMINISTRATION-212]]: Move the ConfigurableClass macros in a macro document, so that they can be reused
49 49  * Various upgrades: JAXB 2.2.2, restlet 1.1.10, Groovy 1.7.7, Jython 2.5.2rc3
... ... @@ -52,6 +52,57 @@
52 52  
53 53  * The following translations have been updated: ##fr##, ##sv##, ##ca##, ##cs##, ##de##, ##es##, ##gl##, ##lv##, ##ro##, ##ru##, ##sk##, ##uk##, ##vi##, ##zh_tw##
54 54  
56 +== Experimental Filesystem Attachment Storage ==
57 +Storage isn't flashy and it isn't exciting, as a user you only have to think about it when it breaks.
58 +Filesystem attachment storage provides you with a means to store large attachments. All data is streamed
59 +from the upload to the filesystem without being held in memory on the way through.
60 +
61 +This means that the only limit on the size of attachments which can be stored is the size of your hard disk.
62 +
63 +Practically, this was tested using a 1GB attachment which uploaded with no problem. A 4GB attachment failed
64 +but the exception message suggests the web browser is to blame.
65 +
66 +=== Set up ===
67 +To try this out for yourself, you will need a copy of XWiki 3.0M2.
68 +Download the 5 parts of the filesystem storage:
69 +* [[Api>>http://hudson.xwiki.org/job/xwiki-platform-core/lastBuild/org.xwiki.platform$xwiki-core-store-api/artifact/org.xwiki.platform/xwiki-core-store-api/3.0-SNAPSHOT/xwiki-core-store-api-3.0-SNAPSHOT.jar]]
70 +* [[Transaction>>http://hudson.xwiki.org/job/xwiki-platform-core/lastBuild/org.xwiki.platform$xwiki-core-store-transaction/artifact/org.xwiki.platform/xwiki-core-store-transaction/3.0-SNAPSHOT/xwiki-core-store-transaction-3.0-SNAPSHOT.jar]]
71 +* [[Serialization>>http://hudson.xwiki.org/job/xwiki-platform-core/lastBuild/org.xwiki.platform$xwiki-core-store-serialization/artifact/org.xwiki.platform/xwiki-core-store-serialization/3.0-SNAPSHOT/xwiki-core-store-serialization-3.0-SNAPSHOT.jar]]
72 +* [[Filesystem Storage>>http://hudson.xwiki.org/job/xwiki-platform-core/lastBuild/org.xwiki.platform$xwiki-core-store-filesystem/artifact/org.xwiki.platform/xwiki-core-store-filesystem/3.0-SNAPSHOT/xwiki-core-store-filesystem-3.0-SNAPSHOT.jar]]
73 +* [[Filesystem Attachment Storage>>http://hudson.xwiki.org/job/xwiki-platform-core/lastBuild/org.xwiki.platform$xwiki-core-store-filesystem-attachments/artifact/org.xwiki.platform/xwiki-core-store-filesystem-attachments/3.0-SNAPSHOT/xwiki-core-store-filesystem-attachments-3.0-SNAPSHOT.jar]]
74 +
75 +{{info}}Development is still progressing and these links will always point to the latest versions of the files so check back from time to time. {{/info}}
76 +
77 +Place these files in your ##xwiki/WEB-INF/lib## directory.
78 +
79 +Then make the following changes to your xwiki.cfg file:
80 +Under the "Storage" section:
81 +
82 +{{code language="none"}}
83 +#-# The attachment storage.
84 +xwiki.store.attachment.hint=file
85 +
86 +#-# The attachment versioning storage. Use 'void' to disable attachment versioning.
87 +xwiki.store.attachment.versioning.hint=file
88 +
89 +#-# Whether the attachment recycle bin feature is activated or not
90 +storage.attachment.recyclebin=0
91 +{{/code}}
92 +
93 +Then start your wiki and as Admin, open this page:
94 +##<your site>/xwiki/bin/edit/XWiki/XWikiPreferences?editor=object##
95 +
96 +Scroll down until you find:
97 +##Maximum Upload Size##
98 +and change that number to something huge like:
99 +99999999999999999 ;)
100 +Press save at the bottom of the page.
101 +
102 +Now go on and upload your giant attachments.
103 +
104 +An attachment recycle bin store is in the works but remains unfinished, the existing code **should** work with the old recycle bin (and it's memory consumption issues) but as of this writing, there exists a bug in the conversion from the new format to the old.
105 +Without a recycel bin store, deletion of attachments is final, rolling back a document will not bring the attachments back.
106 +
55 55  = Known issues =
56 56  
57 57  * [[Bugs we know about>>http://jira.xwiki.org/jira/secure/IssueNavigator.jspa?reset=true&&type=1&pid=10010&resolution=-1&sorter/field=updated&sorter/order=DESC]]

Get Connected