hbaseTemplate test不通过

来源:10-10 Spring Data整合HBase查询功能开发及测试

慕盖茨9116835

2023-02-07

org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘hbaseTemplate’ defined in class path resource [com/garen/webdata/config/HbaseConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.data.hadoop.hbase.HbaseTemplate]: Factory method ‘hbaseTemplate’ threw exception; nested exception is java.lang.NoClassDefFoundError: org/apache/hadoop/hbase/client/HTableInterface

Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.data.hadoop.hbase.HbaseTemplate]: Factory method ‘hbaseTemplate’ threw exception; nested exception is java.lang.NoClassDefFoundError: org/apache/hadoop/hbase/client/HTableInterface

Caused by: java.lang.NoClassDefFoundError: org/apache/hadoop/hbase/client/HTableInterface

Caused by: java.lang.ClassNotFoundException: org.apache.hadoop.hbase.client.HTableInterface

写回答

1回答

Michael_PK

2023-02-08

nested exception is java.lang.NoClassDefFoundError: org/apache/hadoop/hbase/client/HTableInterface


找不到这个类呢,你hbase相应的包在pom里面加了吗? NoClassDefFoundError这是javase最基本的错误呢。

0
0

Spark3实时处理-Streaming+StructuredStreaming实战

实战Spark3实时处理,掌握两套企业级处理方案

347 学习 · 238 问题

查看课程