I don't understand. If you send an insert via XCC, the XCC call does not return 
until the insert is complete. If you POST or PUT to an HTTP service, the HTTP 
call does not return until the insert is complete. Why not simply run your test 
after the insert call or service call returns?

Or is CPF involved, so you need to wait for post-commit triggers to complete? 
If so, you'll have to poll the CPF status of the new document. 
http://docs.marklogic.com/5.0doc/docapp.xqy#display.xqy?fname=http://pubs/5.0doc/apidoc/cpf.xml&category=Content+Processing+Framework&function=cpf:document-get-state
 might help with that.

-- Mike

On 22 Feb 2012, at 10:09 , David Swearingen wrote:

> We are testing some of our document ingestion routines, using JUnit and some 
> other libraries, and we need to understand what the best practice is for 
> dealing with the finite amount of time (often tens of seconds) required to 
> ingest successfully, and thus how to somehow delay our assertions (that 
> ingestion succeeded).  Thanks. 
> 
> _______________________________________________
> General mailing list
> General@developer.marklogic.com
> http://developer.marklogic.com/mailman/listinfo/general

_______________________________________________
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general

Reply via email to