title: Is it important to use FhirInstanceValidator while validating FHIR profiles?
body: <p>I am trying to write validation by using HAPi validation.</p>
  
  <pre><code> FhirContext fhirContext = FhirContext.forR4();
      FhirInstanceValidator instanceValidator = new FhirInstanceValidator();
      FhirValidator validator = fhirContext.newValidator();
  
      validator.registerValidatorModule(instanceValidator);
      ValidationResult result = validator.validateWithResult(requestPayload);
  </code></pre>
  
  <p>Even if I use standard FHIR Patient structure definition , the validation fails.</p>
  
  <p>However if I remove the FHIRInstanceValidator registry code, the validation works fine and returns true.</p>
  
  <p>Where am I going wrong, when is FHIRInstanceValidator actually used?</p>