Pre-requisites: MS Office installed.
1. Enter the following properties in the portal-ext.properties:
2. Install and enable ImageMagick, GhostScript and OpenOffice for preview generation purposes in Server Administration/External Services. You can follow the steps below:
a) Start the portal, go to Control Panel> Server Administration>External Services
b) Under "Enabling ImageMagick and GhostScript provides document preview functionality." click on Enable and enter the paths of GhostScript and ImageMagick as described in this document: https://www.liferay.com/community/wiki/-/wiki/Main/Preview+Generation#section-Preview+Generation-Font+Problems+in+Preview.
(My paths are: C:\Program Files\gs\gs9.15\bin;C:\Program Files\ImageMagick)
c) Ensure to enable the "Enabling OpenOffice integration provides document conversion functionality.", mine is on port 8100 and on the Open Office side I have proceeded with the steps explained here: https://www.liferay.com/community/wiki/-/wiki/Main/Document+Conversion+with+OpenOffice. Save the settings.
Steps to reproduce:
1. Upload a Word document to the Documents and Media.
2. Access it through WEBDAV from MS Explorer. Right-click/Open With MS Word. Provide credentials if prompted. Click Enable Editing.
3. In Liferay, refresh the information screen for the file to check that it is now checked out (locked) and in PWC version.
4. Edit the file in Word then close the Word program. You will be prompted to save your modifications. Click Save. Modifications are saved and Word is closed.
5. Assess the following errors in Tomcat:
14:53:37,516 WARN [http-bio-8080-exec-2][DLWebDAVStorageImpl:842] Unable to unlock file entry
com.liferay.portal.kernel.exception.SystemException: File name version file was not renamed from C:\sorin\IHKBERLIN-1\data\documen
t_library\10155\12601\1501\PWC to C:\sorin\IHKBERLIN-1\data\document_library\10155\12601\1501\1.1
6. Assess in Liferay, that the file is still shown as a draft version.
Expected: The file should have switched to version 1.1 (or whatever the next version would be) and be checked in. the checking in is supposed to be done when the file is closed in Word, or the Word program is closed altogether.
Notes: If you separately save the file, wait a bit, then close it or close Word, the issue does not occur. It also does not occur if the preview generation is disabled, or when using DBStore.