Hi Danny,

Yes, I am using CPF with the Status Change Handling pipeline.  The
logging is not sufficient for my requirements. I need to write the
erroneous document to a special collection that holds erroneous
documents for later investigation of the reason for failure then
correction and re-ingest.  I can put this write into a separate pipeline
called when the document goes into the specified failure state if I'm
guaranteed that the separate pipeline will always be called, even if the
power goes off and is then restored.

Bob


From: Danny Sokolsky <[email protected]>
Subject: [MarkLogic Dev General] RE: Updates within catch blocks
To: General Mark Logic Developer Discussion
        <[email protected]>
Message-ID:
        
<[email protected]>
Content-Type: text/plain; charset="us-ascii"

Hi Bob,

Are you use CPF here with the Status Change Handling pipeline?  I think
it takes care of logging errors with the on-failure action, and logs the
errors to the properties and to the ErrorLog.txt file if it cannot write
to the document.   Is that not sufficient for what you are trying to do?

-Danny

From: [email protected]
[mailto:[email protected]] On Behalf Of Runstein,
Robert E. (Contr) (IS)
Sent: Tuesday, June 02, 2009 8:15 AM
To: [email protected]
Subject: [MarkLogic Dev General] Updates within catch blocks


Hi,

I want to catch an exception, then insert a document representing the
failure then rethrow the original exception.  The xdmp:rethrow() appears
to cause the insert to get rolled back.  I have tried wrapping the
xdmp:document-insert call in xdmp:invoke with isolation set to
different-transaction, but the insert still does not persist.  The
module is called from a pipeline, so it is important that I report the
failure condition.  While I could do the insert in a following pipeline
triggered by the failure, I am concerned that there might be a
circumstance under which the following pipeline might not get executed
and the insert would never take place.

Is there a way to persist the insert within the catch block?  Am I being
overly paranoid in worrying that the insert would never take place if
done in a following pipeline?

Thanks.

Bob Runstein

_______________________________________________
General mailing list
[email protected]
http://xqzone.com/mailman/listinfo/general

Reply via email to