static Document copyDocument(Document input) throws TransformerException {
        Transformer transformer = TransformerFactory.newInstance().newTransformer();
        DOMSource source = new DOMSource(input);
        DOMResult result = new DOMResult();
        transformer.transform(source, result);
        return (Document) result.getNode();
    }
Creates a new XML document builder.

@return a new DocumentBuilder instance, or null if we fail to get one.
config-application-package/src/main/java/com/yahoo/config/application/Xml.java