How does one trap an error on a driver?
What I want to do, is every time the subscriber sends a modify (LDAP driver) if an error is returned, then I want an email sent to me with what the object is and the type of error.

Looking at the default config, it looks like a condition set of:
<conditions>
<and>
<if-operation op="equal">status</if-operation>
<if-xpath op="true">self::status[@level != 'error']/operation-data</if-xpath>
</and>
</conditions>

Then to get the error value out I could use:
<token-xpath expression="self::status/operation-data/message"/>
and the object:
<token-xpath expression="self::status/operation-data/association"/>

Of course stuffing the resultant rule into the publisher input transform?

Looking at an example error:
<nds dtdversion="2.0" ndsversion="8.x">
<source>
<product build="20070301_0603 " instance="OAC7 DC Model" version="3.5.0">Identity Manager Driver for LDAP</product>
<contact>Novell, Inc.</contact>
</source>
<output>
<status event-id="UTHSCH-1#20070705145402#1#1" level="error">LDAPException: Object Class Violation (65) Object Class Violation LDAPException: Matched DN: </status>
</output>
</nds>

I see that the object is not included. Does that mean I need a generic rule on the sub-out-trans to stuff some operation data in there?

Thanks!