Remove the operation to make xdt idempotent. Move the template to embedd...

...ed resourse.
Fixes #1252