Alibaba Cloud DLF

Data Lake Formation (DLF) is the unified metadata management service of Alibaba Cloud. It is compatible with the Hive Metastore protocol.

What is DLF

Doris can access DLF the same way as it accesses Hive Metastore.

Connect to DLF

The First Way, Create a Hive Catalog.

  1. CREATE CATALOG hive_with_dlf PROPERTIES (
  2. "type"="hms",
  3. "dlf.catalog.proxyMode" = "DLF_ONLY",
  4. "hive.metastore.type" = "dlf",
  5. "dlf.catalog.endpoint" = "dlf.cn-beijing.aliyuncs.com",
  6. "dlf.catalog.region" = "cn-beijing",
  7. "dlf.catalog.uid" = "uid",
  8. "dlf.catalog.accessKeyId" = "ak",
  9. "dlf.catalog.accessKeySecret" = "sk"
  10. );

type should always be hms. If you need to access Alibaba Cloud OSS on the public network, can add "dlf.catalog.accessPublic"="true".

Other configuration items are fixed and require no modifications.

After the above steps, you can access metadata in DLF the same way as you access Hive MetaStore.

Doris supports accessing Hive/Iceberg/Hudi metadata in DLF.

The Second Way, Configure the Hive Conf

  1. Create the hive-site.xml file, and put it in the fe/conf directory.
  1. <?xml version="1.0"?>
  2. <configuration>
  3. <!--Set to use dlf client-->
  4. <property>
  5. <name>hive.metastore.type</name>
  6. <value>dlf</value>
  7. </property>
  8. <property>
  9. <name>dlf.catalog.endpoint</name>
  10. <value>dlf-vpc.cn-beijing.aliyuncs.com</value>
  11. </property>
  12. <property>
  13. <name>dlf.catalog.region</name>
  14. <value>cn-beijing</value>
  15. </property>
  16. <property>
  17. <name>dlf.catalog.proxyMode</name>
  18. <value>DLF_ONLY</value>
  19. </property>
  20. <property>
  21. <name>dlf.catalog.uid</name>
  22. <value>20000000000000000</value>
  23. </property>
  24. <property>
  25. <name>dlf.catalog.accessKeyId</name>
  26. <value>XXXXXXXXXXXXXXX</value>
  27. </property>
  28. <property>
  29. <name>dlf.catalog.accessKeySecret</name>
  30. <value>XXXXXXXXXXXXXXXXX</value>
  31. </property>
  32. </configuration>
  1. Restart FE, Doris will read and parse fe/conf/hive-site.xml. And then Create Catalog via the CREATE CATALOG statement.
  1. CREATE CATALOG hive_with_dlf PROPERTIES (
  2. "type"="hms",
  3. "hive.metastore.uris" = "thrift://127.0.0.1:9083"
  4. )

type should always be hms; while hive.metastore.uris can be arbitary since it is not used in real practice, but it should follow the format of Hive Metastore Thrift URI.