Class OSSURI

java.lang.Object
org.apache.iceberg.aliyun.oss.OSSURI

public class OSSURI extends Object
This class represents a fully qualified location in OSS for input/output operations expressed as as URI. This implementation is provided to ensure compatibility with Hadoop Path implementations that may introduce encoding issues with native URI implementation.

Note: Path-style access is deprecated and not supported by this implementation.

  • Constructor Summary

    Constructors
    Constructor
    Description
    OSSURI(String location)
    Creates a new OSSURI based on the bucket and key parsed from the location The location in string form has the syntax as below, which refers to RFC2396: [scheme:][//bucket][object key][#fragment] [scheme:][//bucket][object key][?query][#fragment]
  • Method Summary

    Modifier and Type
    Method
    Description
    Return OSS bucket name.
    key()
    Return OSS object key name.
    Return original, unmodified OSS URI location.
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • OSSURI

      public OSSURI(String location)
      Creates a new OSSURI based on the bucket and key parsed from the location The location in string form has the syntax as below, which refers to RFC2396: [scheme:][//bucket][object key][#fragment] [scheme:][//bucket][object key][?query][#fragment]

      It specifies precisely which characters are permitted in the various components of a URI reference in Aliyun OSS documentation as below: Bucket: https://help.aliyun.com/document_detail/257087.html Object: https://help.aliyun.com/document_detail/273129.html Scheme: https or oss

      Supported access styles are https and oss://... URIs.

      Parameters:
      location - fully qualified URI.
  • Method Details

    • bucket

      public String bucket()
      Return OSS bucket name.
    • key

      public String key()
      Return OSS object key name.
    • location

      public String location()
      Return original, unmodified OSS URI location.
    • toString

      public String toString()
      Overrides:
      toString in class Object