All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.openmetadata.schema.services.connections.database.DatalakeConnection Maven / Gradle / Ivy

There is a newer version: 1.6.0-rc1
Show newest version

package org.openmetadata.schema.services.connections.database;

import java.util.HashMap;
import java.util.Map;
import javax.annotation.processing.Generated;
import javax.validation.Valid;
import javax.validation.constraints.NotNull;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyDescription;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.fasterxml.jackson.annotation.JsonValue;


/**
 * DatalakeConnection
 * 

* Datalake Connection Config * */ @JsonInclude(JsonInclude.Include.NON_NULL) @JsonPropertyOrder({ "type", "configSource", "bucketName", "prefix", "databaseName", "connectionOptions", "connectionArguments", "supportsMetadataExtraction", "supportsProfiler", "sampleDataStorageConfig" }) @Generated("jsonschema2pojo") public class DatalakeConnection { /** * Service type. * */ @JsonProperty("type") @JsonPropertyDescription("Service type.") private DatalakeConnection.DatalakeType type = DatalakeConnection.DatalakeType.fromValue("Datalake"); /** * DataLake Configuration Source *

* Available sources to fetch files. * (Required) * */ @JsonProperty("configSource") @JsonPropertyDescription("Available sources to fetch files.") @NotNull private Object configSource; /** * Bucket Name *

* Bucket Name of the data source. * */ @JsonProperty("bucketName") @JsonPropertyDescription("Bucket Name of the data source.") private String bucketName = ""; /** * Prefix *

* Prefix of the data source. * */ @JsonProperty("prefix") @JsonPropertyDescription("Prefix of the data source.") private String prefix = ""; /** * Database Name *

* Optional name to give to the database in OpenMetadata. If left blank, we will use default as the database name. * */ @JsonProperty("databaseName") @JsonPropertyDescription("Optional name to give to the database in OpenMetadata. If left blank, we will use default as the database name.") private String databaseName; /** * Additional connection options to build the URL that can be sent to service during the connection. * */ @JsonProperty("connectionOptions") @JsonPropertyDescription("Additional connection options to build the URL that can be sent to service during the connection.") @Valid private ConnectionOptions connectionOptions; /** * Additional connection arguments such as security or protocol configs that can be sent to service during connection. * */ @JsonProperty("connectionArguments") @JsonPropertyDescription("Additional connection arguments such as security or protocol configs that can be sent to service during connection.") @Valid private ConnectionArguments connectionArguments; /** * Supports Metadata Extraction. * */ @JsonProperty("supportsMetadataExtraction") @JsonPropertyDescription("Supports Metadata Extraction.") private Boolean supportsMetadataExtraction = true; /** * Supports Profiler * */ @JsonProperty("supportsProfiler") @JsonPropertyDescription("Supports Profiler") private Boolean supportsProfiler = true; /** * Storage config to store sample data * */ @JsonProperty("sampleDataStorageConfig") @JsonPropertyDescription("Storage config to store sample data") @Valid private SampleDataStorageConfig sampleDataStorageConfig; /** * Service type. * */ @JsonProperty("type") public DatalakeConnection.DatalakeType getType() { return type; } /** * Service type. * */ @JsonProperty("type") public void setType(DatalakeConnection.DatalakeType type) { this.type = type; } public DatalakeConnection withType(DatalakeConnection.DatalakeType type) { this.type = type; return this; } /** * DataLake Configuration Source *

* Available sources to fetch files. * (Required) * */ @JsonProperty("configSource") public Object getConfigSource() { return configSource; } /** * DataLake Configuration Source *

* Available sources to fetch files. * (Required) * */ @JsonProperty("configSource") public void setConfigSource(Object configSource) { this.configSource = configSource; } public DatalakeConnection withConfigSource(Object configSource) { this.configSource = configSource; return this; } /** * Bucket Name *

* Bucket Name of the data source. * */ @JsonProperty("bucketName") public String getBucketName() { return bucketName; } /** * Bucket Name *

* Bucket Name of the data source. * */ @JsonProperty("bucketName") public void setBucketName(String bucketName) { this.bucketName = bucketName; } public DatalakeConnection withBucketName(String bucketName) { this.bucketName = bucketName; return this; } /** * Prefix *

* Prefix of the data source. * */ @JsonProperty("prefix") public String getPrefix() { return prefix; } /** * Prefix *

* Prefix of the data source. * */ @JsonProperty("prefix") public void setPrefix(String prefix) { this.prefix = prefix; } public DatalakeConnection withPrefix(String prefix) { this.prefix = prefix; return this; } /** * Database Name *

* Optional name to give to the database in OpenMetadata. If left blank, we will use default as the database name. * */ @JsonProperty("databaseName") public String getDatabaseName() { return databaseName; } /** * Database Name *

* Optional name to give to the database in OpenMetadata. If left blank, we will use default as the database name. * */ @JsonProperty("databaseName") public void setDatabaseName(String databaseName) { this.databaseName = databaseName; } public DatalakeConnection withDatabaseName(String databaseName) { this.databaseName = databaseName; return this; } /** * Additional connection options to build the URL that can be sent to service during the connection. * */ @JsonProperty("connectionOptions") public ConnectionOptions getConnectionOptions() { return connectionOptions; } /** * Additional connection options to build the URL that can be sent to service during the connection. * */ @JsonProperty("connectionOptions") public void setConnectionOptions(ConnectionOptions connectionOptions) { this.connectionOptions = connectionOptions; } public DatalakeConnection withConnectionOptions(ConnectionOptions connectionOptions) { this.connectionOptions = connectionOptions; return this; } /** * Additional connection arguments such as security or protocol configs that can be sent to service during connection. * */ @JsonProperty("connectionArguments") public ConnectionArguments getConnectionArguments() { return connectionArguments; } /** * Additional connection arguments such as security or protocol configs that can be sent to service during connection. * */ @JsonProperty("connectionArguments") public void setConnectionArguments(ConnectionArguments connectionArguments) { this.connectionArguments = connectionArguments; } public DatalakeConnection withConnectionArguments(ConnectionArguments connectionArguments) { this.connectionArguments = connectionArguments; return this; } /** * Supports Metadata Extraction. * */ @JsonProperty("supportsMetadataExtraction") public Boolean getSupportsMetadataExtraction() { return supportsMetadataExtraction; } /** * Supports Metadata Extraction. * */ @JsonProperty("supportsMetadataExtraction") public void setSupportsMetadataExtraction(Boolean supportsMetadataExtraction) { this.supportsMetadataExtraction = supportsMetadataExtraction; } public DatalakeConnection withSupportsMetadataExtraction(Boolean supportsMetadataExtraction) { this.supportsMetadataExtraction = supportsMetadataExtraction; return this; } /** * Supports Profiler * */ @JsonProperty("supportsProfiler") public Boolean getSupportsProfiler() { return supportsProfiler; } /** * Supports Profiler * */ @JsonProperty("supportsProfiler") public void setSupportsProfiler(Boolean supportsProfiler) { this.supportsProfiler = supportsProfiler; } public DatalakeConnection withSupportsProfiler(Boolean supportsProfiler) { this.supportsProfiler = supportsProfiler; return this; } /** * Storage config to store sample data * */ @JsonProperty("sampleDataStorageConfig") public SampleDataStorageConfig getSampleDataStorageConfig() { return sampleDataStorageConfig; } /** * Storage config to store sample data * */ @JsonProperty("sampleDataStorageConfig") public void setSampleDataStorageConfig(SampleDataStorageConfig sampleDataStorageConfig) { this.sampleDataStorageConfig = sampleDataStorageConfig; } public DatalakeConnection withSampleDataStorageConfig(SampleDataStorageConfig sampleDataStorageConfig) { this.sampleDataStorageConfig = sampleDataStorageConfig; return this; } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append(DatalakeConnection.class.getName()).append('@').append(Integer.toHexString(System.identityHashCode(this))).append('['); sb.append("type"); sb.append('='); sb.append(((this.type == null)?"":this.type)); sb.append(','); sb.append("configSource"); sb.append('='); sb.append(((this.configSource == null)?"":this.configSource)); sb.append(','); sb.append("bucketName"); sb.append('='); sb.append(((this.bucketName == null)?"":this.bucketName)); sb.append(','); sb.append("prefix"); sb.append('='); sb.append(((this.prefix == null)?"":this.prefix)); sb.append(','); sb.append("databaseName"); sb.append('='); sb.append(((this.databaseName == null)?"":this.databaseName)); sb.append(','); sb.append("connectionOptions"); sb.append('='); sb.append(((this.connectionOptions == null)?"":this.connectionOptions)); sb.append(','); sb.append("connectionArguments"); sb.append('='); sb.append(((this.connectionArguments == null)?"":this.connectionArguments)); sb.append(','); sb.append("supportsMetadataExtraction"); sb.append('='); sb.append(((this.supportsMetadataExtraction == null)?"":this.supportsMetadataExtraction)); sb.append(','); sb.append("supportsProfiler"); sb.append('='); sb.append(((this.supportsProfiler == null)?"":this.supportsProfiler)); sb.append(','); sb.append("sampleDataStorageConfig"); sb.append('='); sb.append(((this.sampleDataStorageConfig == null)?"":this.sampleDataStorageConfig)); sb.append(','); if (sb.charAt((sb.length()- 1)) == ',') { sb.setCharAt((sb.length()- 1), ']'); } else { sb.append(']'); } return sb.toString(); } @Override public int hashCode() { int result = 1; result = ((result* 31)+((this.bucketName == null)? 0 :this.bucketName.hashCode())); result = ((result* 31)+((this.supportsMetadataExtraction == null)? 0 :this.supportsMetadataExtraction.hashCode())); result = ((result* 31)+((this.databaseName == null)? 0 :this.databaseName.hashCode())); result = ((result* 31)+((this.supportsProfiler == null)? 0 :this.supportsProfiler.hashCode())); result = ((result* 31)+((this.connectionOptions == null)? 0 :this.connectionOptions.hashCode())); result = ((result* 31)+((this.prefix == null)? 0 :this.prefix.hashCode())); result = ((result* 31)+((this.sampleDataStorageConfig == null)? 0 :this.sampleDataStorageConfig.hashCode())); result = ((result* 31)+((this.type == null)? 0 :this.type.hashCode())); result = ((result* 31)+((this.configSource == null)? 0 :this.configSource.hashCode())); result = ((result* 31)+((this.connectionArguments == null)? 0 :this.connectionArguments.hashCode())); return result; } @Override public boolean equals(Object other) { if (other == this) { return true; } if ((other instanceof DatalakeConnection) == false) { return false; } DatalakeConnection rhs = ((DatalakeConnection) other); return (((((((((((this.bucketName == rhs.bucketName)||((this.bucketName!= null)&&this.bucketName.equals(rhs.bucketName)))&&((this.supportsMetadataExtraction == rhs.supportsMetadataExtraction)||((this.supportsMetadataExtraction!= null)&&this.supportsMetadataExtraction.equals(rhs.supportsMetadataExtraction))))&&((this.databaseName == rhs.databaseName)||((this.databaseName!= null)&&this.databaseName.equals(rhs.databaseName))))&&((this.supportsProfiler == rhs.supportsProfiler)||((this.supportsProfiler!= null)&&this.supportsProfiler.equals(rhs.supportsProfiler))))&&((this.connectionOptions == rhs.connectionOptions)||((this.connectionOptions!= null)&&this.connectionOptions.equals(rhs.connectionOptions))))&&((this.prefix == rhs.prefix)||((this.prefix!= null)&&this.prefix.equals(rhs.prefix))))&&((this.sampleDataStorageConfig == rhs.sampleDataStorageConfig)||((this.sampleDataStorageConfig!= null)&&this.sampleDataStorageConfig.equals(rhs.sampleDataStorageConfig))))&&((this.type == rhs.type)||((this.type!= null)&&this.type.equals(rhs.type))))&&((this.configSource == rhs.configSource)||((this.configSource!= null)&&this.configSource.equals(rhs.configSource))))&&((this.connectionArguments == rhs.connectionArguments)||((this.connectionArguments!= null)&&this.connectionArguments.equals(rhs.connectionArguments)))); } /** * Service type. * */ @Generated("jsonschema2pojo") public enum DatalakeType { DATALAKE("Datalake"); private final String value; private final static Map CONSTANTS = new HashMap(); static { for (DatalakeConnection.DatalakeType c: values()) { CONSTANTS.put(c.value, c); } } DatalakeType(String value) { this.value = value; } @Override public String toString() { return this.value; } @JsonValue public String value() { return this.value; } @JsonCreator public static DatalakeConnection.DatalakeType fromValue(String value) { DatalakeConnection.DatalakeType constant = CONSTANTS.get(value); if (constant == null) { throw new IllegalArgumentException(value); } else { return constant; } } } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy