Search code examples
xpageslotus-domino

Deletion of document via XPage doesn’t cause deletion of DAOS enabled attachments


Need your help in the following issue:

I have DAOS enabled XPage application (NSF database). All attachments go to DAOS NLOs when uploaded via XPage. When deleting documents via View (in Notes) – documents are being deleted with its NLO-attachments as expected.

Issue with deleting documents via XPage: doing it like

dataSource.getDocument().removePermanently(true)

deletes document but doesn’t delete NLO-attachments from DAOS.

The App database still contains DAOS tickets. Only helps command “load compact -c appDBname.nsf”. Compact causes DBPrune, which cleans that lost (not referenced) NLOs.

Additional information:

  • It is Domino 9.0 Server.
  • DAOS param “Defer object deletion for” set to “0”.
  • Nightly Daos Prunes also doesn’t clean NLOs (log content: DAOSMGR: DbDelete started -> DAOSMGR: Prune 0 started -> DAOSMGR: DbDelete completed -> DAOS Prune - Deleted 0 objects and completed with error: (0) No error -> DAOSMGR: Prune 0 completed).
  • APP DB has “Synchronized” state.
  • It’s clean test environment with only one single app, so it is definitely that there are no other applications, which refer to the same NLOs.

Any ideas & advices? Thanks in advance!


Solution

  • So, I can close the issue with the following workaround. As I wrote before, to not have such issue - deletion should be performed by user with at least Editor access level.

    So, as workaround: use SSJS and get document via SessionAsSigner.

    I didn't find yet explanation in documentation why it depends on access level...