問題背景
在Flink的sql-client客戶端中執(zhí)行連接hive的sql代碼時(shí)出現(xiàn)如下錯(cuò)誤,版本Flink1.13.6
Flink SQL> ?create catalog test?with(
> ?'type'='hive',
> 'default-database'='default',
> 'hive-conf-dir'='/opt/hive/conf');
[ERROR] Could not execute SQL statement. Reason:
java.lang.ClassNotFoundException: org.apache.hadoop.conf.Configuration
問題原因
Flink最初是解壓lib目錄中并沒有hadoop相關(guān)的依賴,需要補(bǔ)充Hdoop相關(guān)的依賴,根據(jù)下面的資料,hadoop大于2的版本兼容包為flink-shaded-hadoop2,文章來源:http://www.zghlxwxcb.cn/news/detail-833244.html
Hadoop 文章來源地址http://www.zghlxwxcb.cn/news/detail-833244.html
到了這里,關(guān)于【Flink】ClassNotFoundException: org.apache.hadoop.conf.Configuration的文章就介紹完了。如果您還想了解更多內(nèi)容,請(qǐng)?jiān)谟疑辖撬阉鱐OY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!