I have a fairly simple need to do a conditional update in Solr, which is easily accomplished in MySQL.
For example,
As of solr 4.0, optimistic concurrency is enabled via the _version_ field.
_version_
http://yonik.com/solr/optimistic-concurrency/
To enable, you need to make sure your schema.xml contains
and in solrconfig.xml
${solr.data.dir:}