private String getSchema(HyscaleSpecType type) throws HyscaleException{
        String schemaPath = getSchemaPath(type);
        try (InputStream is = SchemaValidator.class.getClassLoader().getResourceAsStream(schemaPath)) {
            if (is == null) {
                HyscaleException ex = new HyscaleException(CommonErrorCode.FAILED_TO_READ_FILE, schemaPath);
                LOGGER.error(ex.getMessage());
                throw ex;
            }
            return new String(is.readAllBytes(), StandardCharsets.UTF_8);
        } catch (IOException e) {
            HyscaleException ex = new HyscaleException(e, CommonErrorCode.ERROR_OCCURED_WHILE_SCHEMA_VALIDATION, e.getMessage());
            LOGGER.error(ex.getMessage());
            throw ex;
        }
    }
validates whether the given spec file satisfies respective reference schema.

@param specFile
@param type
@return ProcessingReport
@throws HyscaleException
service-spec/schema-validator/src/main/java/io/hyscale/schema/validator/SchemaValidator.java