Synchronized DocumentBuilder.parse() to avoid NPE