代码
package com.imooc.bigdata.log.utils;
import com.imooc.bigdata.gen.LogGenerator;
public class Test {
public static void main(String[] args) throws Exception{
String url = "http://hadoop000:9527/pk-web/upload";
String code = "123456";
LogGenerator.generator(url,code);
}
}
报错如下
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/http/client/methods/HttpUriRequest
at com.imooc.bigdata.log.utils.Test.main(Test.java:9)
Caused by: java.lang.ClassNotFoundException: org.apache.http.client.methods.HttpUriRequest
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
... 1 more