jcplerm wrote:
I am trying to figure out how to identify when an exception is related to trying to remove a document that does not exist anymore.
In this type of situation I would just like to ignore it and continue normally (I don't care, if it's no longer there, good!).
But the XMLDBException does not report a code for this condition all codes are set to ZERO).

...

The code above prints something like:
XMLDBException code: 0
Cause class: class org.apache.xmlrpc.XmlRpcException
Cause code: 0
Cause msg: java.lang.Exception: org.apache.xindice.core.DBException: Document Does Not Exist
At best I could parse the message of the XmlRpcException for substring "Document Does Not Exist".
This is like pulling tooth....
All codes set to ZERO: this is tough!!!

You've got several options:

1) Find where exceptions are thrown with code 0 and write an email to
-dev list stating that
2) Patch code and send a patch to -dev list
3) Patch code, add a unit test to the integration test suite, and send
patch and test to the -dev list

Last option is the best one! :)

Vadim




Reply via email to