@Override public CompatibilityResult checkForCompatibility(SchemaMetadata schemaMetadata, String toSchemaText, String existingSchemaText) { return checkCompatibility(schemaMetadata.getType(), toSchemaText, existingSchemaText, schemaMetadata.getCompatibility()); }
@Override public int hashCode() { int result = type != null ? type.hashCode() : 0; result = 31 * result + (schemaGroup != null ? schemaGroup.hashCode() : 0); result = 31 * result + (name != null ? name.hashCode() : 0); result = 31 * result + (description != null ? description.hashCode() : 0); result = 31 * result + (getCompatibility() != null ? getCompatibility().hashCode() : 0); result = 31 * result + (getValidationLevel() != null ? getValidationLevel().hashCode() : 0); result = 31 * result + (evolve ? 1 : 0); return result; }
@Override public int hashCode() { int result = type != null ? type.hashCode() : 0; result = 31 * result + (schemaGroup != null ? schemaGroup.hashCode() : 0); result = 31 * result + (name != null ? name.hashCode() : 0); result = 31 * result + (description != null ? description.hashCode() : 0); result = 31 * result + (getCompatibility() != null ? getCompatibility().hashCode() : 0); result = 31 * result + (getValidationLevel() != null ? getValidationLevel().hashCode() : 0); result = 31 * result + (evolve ? 1 : 0); return result; }
@Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; SchemaMetadata that = (SchemaMetadata) o; if (evolve != that.evolve) return false; if (type != null ? !type.equals(that.type) : that.type != null) return false; if (schemaGroup != null ? !schemaGroup.equals(that.schemaGroup) : that.schemaGroup != null) return false; if (name != null ? !name.equals(that.name) : that.name != null) return false; if (description != null ? !description.equals(that.description) : that.description != null) return false; if (getValidationLevel() != null ? !getValidationLevel().equals(that.getValidationLevel()) : that.getValidationLevel() != null) return false; return getCompatibility() == that.getCompatibility(); }
@Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; SchemaMetadata that = (SchemaMetadata) o; if (evolve != that.evolve) return false; if (type != null ? !type.equals(that.type) : that.type != null) return false; if (schemaGroup != null ? !schemaGroup.equals(that.schemaGroup) : that.schemaGroup != null) return false; if (name != null ? !name.equals(that.name) : that.name != null) return false; if (description != null ? !description.equals(that.description) : that.description != null) return false; if (getValidationLevel() != null ? !getValidationLevel().equals(that.getValidationLevel()) : that.getValidationLevel() != null) return false; return getCompatibility() == that.getCompatibility(); }
public Builder(SchemaMetadata schemaMetadata) { name = schemaMetadata.getName(); type = schemaMetadata.getType(); schemaGroup = schemaMetadata.getSchemaGroup(); description = schemaMetadata.getDescription(); compatibility = schemaMetadata.getCompatibility(); validationLevel = schemaMetadata.getValidationLevel(); evolve = schemaMetadata.isEvolve(); }
public Builder(SchemaMetadata schemaMetadata) { name = schemaMetadata.getName(); type = schemaMetadata.getType(); schemaGroup = schemaMetadata.getSchemaGroup(); description = schemaMetadata.getDescription(); compatibility = schemaMetadata.getCompatibility(); validationLevel = schemaMetadata.getValidationLevel(); evolve = schemaMetadata.isEvolve(); }
toSchema, latestSchemaVersionInfo.getSchemaText(), schemaMetadata.getCompatibility()); if (!compatibilityResult.isCompatible()) { LOG.info("Received schema is not compatible with the latest schema versions [{}] with schema name [{}]", toSchema, schemaVersionInfo.getSchemaText(), schemaMetadata.getCompatibility()); if (!compatibilityResult.isCompatible()) { LOG.info("Received schema is not compatible with one of the schema versions [{}] with schema name [{}]",
public static SchemaMetadataStorable updateSchemaMetadata(SchemaMetadataStorable schemaMetadataStorable, SchemaMetadata schemaMetadata) { schemaMetadataStorable.setType(schemaMetadata.getType()); schemaMetadataStorable.setSchemaGroup(schemaMetadata.getSchemaGroup()); schemaMetadataStorable.setName(schemaMetadata.getName()); schemaMetadataStorable.setDescription(schemaMetadata.getDescription()); schemaMetadataStorable.setCompatibility(schemaMetadata.getCompatibility()); schemaMetadataStorable.setValidationLevel(schemaMetadata.getValidationLevel()); schemaMetadataStorable.setEvolve(schemaMetadata.isEvolve()); return schemaMetadataStorable; }