[ https://issues.apache.org/jira/browse/HBASE-24539?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17133642#comment-17133642 ]
Marc Parisi commented on HBASE-24539: ------------------------------------- perfect [~bharathv] ! Will take a look, thanks! > Fix the classpath for the local mini-cluster > -------------------------------------------- > > Key: HBASE-24539 > URL: https://issues.apache.org/jira/browse/HBASE-24539 > Project: HBase > Issue Type: Sub-task > Components: Client, native-client > Affects Versions: 3.0.0-alpha-1 > Reporter: Bharath Vissapragada > Assignee: Marc Parisi > Priority: Major > > The classpath is created assuming the native-client is a module of the parent > hbase repo. Since that is not the case anymore and we rely on a dynamically > pulled HBase version, we need to fix the classpath for the JVM that is spun > using JNI. Otherwise mini-cluster won't start.. > {noformat} > using hbase::MiniCluster; > JNIEnv *MiniCluster::CreateVM(JavaVM **jvm) { > JavaVMInitArgs args; > JavaVMOption jvm_options; > args.version = JNI_VERSION_1_6; > args.nOptions = 1; > char *classpath = getenv("CLASSPATH"); > std::string clspath; > if (classpath == NULL || strstr(classpath, "-tests.jar") == NULL) { > std::string > clsPathFilePath("../../../hbase-build-configuration/target/cached_classpath.txt"); > std::ifstream fd(clsPathFilePath); > std::string prefix(""); > if (fd.is_open()) { > if (classpath == NULL) { > LOG(INFO) << "got empty classpath"; > } else { > // prefix bootstrapper.jar > prefix.assign(classpath); > } > std::string line; > {noformat} > > -- This message was sent by Atlassian Jira (v8.3.4#803005)