code: private static Schema getSchema(InputStream schemaStream) throws SAXException {
          Schema result;
          synchronized(SCHEMA_FACTORY){
              result = SCHEMA_FACTORY.newSchema(new StreamSource(schemaStream));
          }
          return result;
      }
docs: Schema Factory is not thread safe
  @return