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

io.openlineage.client.transports.gcs.GcsTransportBuilder Maven / Gradle / Ivy

There is a newer version: 1.26.0
Show newest version
/*
/* Copyright 2018-2024 contributors to the OpenLineage project
/* SPDX-License-Identifier: Apache-2.0
*/

package io.openlineage.client.transports.gcs;

import io.openlineage.client.OpenLineageClientException;
import io.openlineage.client.transports.Transport;
import io.openlineage.client.transports.TransportBuilder;
import io.openlineage.client.transports.TransportConfig;
import java.io.IOException;

public class GcsTransportBuilder implements TransportBuilder {
  @Override
  public String getType() {
    return "gcs";
  }

  @Override
  public TransportConfig getConfig() {
    return new GcsTransportConfig();
  }

  @Override
  public Transport build(TransportConfig config) {
    try {
      return new GcsTransport((GcsTransportConfig) config);
    } catch (IOException e) {
      throw new OpenLineageClientException(
          "An exception occurred while creating a GcsTransport", e);
    }
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy