现在linux机器,安装thrift
[root@localhost workspace]# thrift -version
Thrift version 0.14.0
然后编写hello.thrift文件
service HelloService {
string sayHello (1: string name);
}
再执行
thrift -gen java hello.thrift
然后打开当前目录下HelloService.java
把文件放到eclipse下,开始编写服务端和客户端
发现报错
maven的pom文件:
<dependency>
<groupId>org.apache.thrift</groupId>
<artifactId>libthrift</artifactId>
<version>0.10.0</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
<version>1.7.5</version>
</dependency>
网友们知道什么原因吗,百度也没查到对应问题