(originally posted on http://www.liferay.com/community/forums/-/message_boards/message/14746822)
I am using Liferay Portal 6.1 EE to implement a custom document store backed by Oracle UCM. I've run into an issue that I think is related to other defects I see related to wiki attachments.
My custom document store receives this sequence of calls when I add an attachment to a wiki (or messageboard):
- addFile: companyId=999, repositoryId=0, dirName=wiki/12802/My Document.doc
- getFileNames: companyId=999, repositoryId=0, dirName=wiki/12802
- getFileSize:companyId=999, repositoryId=0, filePath=My Document.doc
Steps 1 and 2 are fine here, but the filePath in step 3 is a concern because it lacks the "wiki/" prefix, so I don't find the exact document. The file was stored in the repository at /Contribution Folders/Liferay/999/documentLibrary/0/wiki/12802/My Document.doc. Without the "wiki/" prefix on the filename, my code looks in a nonexistent folder.
Deleting wiki attachments seems to have the same problem (missing "wiki/" prefix on filename)
This is pretty easy to reproduce, or to at least catch with the debugger.