See FilesResource and TestFilesResource.
Also check the servlets and auth filter.
- Use CoreInstance#openCoreSession
- Error handling, use exception for 404 / 500 / 400 ...
- remove WOPIForwardServlet
- Remove FileInfo, replace it by a simple Map to be written
- Use HttpHeaders and enum for WOPI actions
- Remove stores-contrib.xml as it should be not needed. Asking for a store name creates a new store based on the default descriptor.
https://github.com/nuxeo/nuxeo-wopi/pull/1#discussion_r202083554Note that we don't contribute explicitly a KeyValueStore, we leverage the default one.
As it, we only have one contribution to switch all K/V from Mem to Redis/MongoDB.
We're used to suffix all of our keys for this reason. - Use CoreSession#SOURCE instead of hardcoding "source"