code: protected Schema getFieldSchema(GenericRecord record, String schemaIdLocation) throws Exception {
      Optional<Object> schemaIdValue = AvroUtils.getFieldValue(record, schemaIdLocation);
      if (!schemaIdValue.isPresent()) {
        throw new Exception("Schema id with key " + schemaIdLocation + " not found in the record");
      }
      String schemaKey = String.valueOf(schemaIdValue.get());
      return (Schema) registry.getSchemaByKey(schemaKey);
    }
docs: Get the schema of a field
  
  @param record the input record which has the schema id
  @param schemaIdLocation a dot separated location string the schema id
  @return a schema referenced by the schema id