Q:

To get details or to retrieve deleted notes documents

what i am doing : 
from java code i am retrieving notes database and indexing all the documents of that database using full text indexing 
using solrj client and saving the indexed data of particular documents on Full text server. 
suppose when same database comes again for indexing, considered any one of the documents from that database is deleted which is already indexed on Full text server,
But this document is deleted from notes database so i don't want to keep (means want to delete) indexed data on my full text server of deleted document.
so how would I know which document is deleted 
what i am thinking is , Store document's id and db name while indexing, so i will have record of indexed documents, so i can identify which documents are deleted from particular database. 
any other efficient way? 
Thank you  for reading question. 

A:

The Document universal id of a document is a unique identifier at least for a complete database.  
You can get it with Document.getUniversalID() in Java
By design every unique id is unique worldwide, but as a designer you can go around that (unids are writable) and replicas of course have documents with the same unique id.  
Combine the unid with the filepath of the database, then it REALLY is unique. 
Now just remember all unids you indexed and after the next run check, if there were some, that you couldn't find anymore (e.g. just remove every "found" unid - path key from you existing indices- list and whatever is in there in the end does not exist anymore). 
BACKGROUND
Every document that is deleted in a NSF- Database becomes a so called Deletion Stub for (at least) 90 days before it is purged finally.
The interval is configurable for each database, can be less than 90 days, if admin decided so... 
These deletion stubs still contain the unid as information. They would be perfect for your purpose (as that is exactly their purpose for the internal processes called replication).  
Unfortunately there is no easy way to get these deletion stubs for a database with Java.
There are ways to get them with external tools or C-API from LotusScript, but none of them is easy to use from Java. 

