During story #24970, we added the possibility of setting reverse links when creating a new artifact (via the REST API). However, if there is an error during the update of one of the artifacts that is source of a reverse link, it should cancel the artifact creation as well. It does not appear in the Acceptance criteria of the story, but it was pretty clear from chat messages that the rollback of the whole operation was wanted (see excerpt, in French):
Il y a une big transaction qui entoure à la fois la modification de l'artéfact "courant" et la modification de tous les artéfacts "liants" (avec un lien direction "reverse"). Si la modification de l'artéfact "courant" est rejetée ou bien la modification de l'artéfact "liant" est rejetée, pour une des raisons suivantes, alors la big transaction est rollback, et rien n'est modifié[...]
We should wrap the whole block in a database transaction: creation + update of reverse links.