Hi Chris, Thanks for the notification.
Indeed we need the library to let users use our api in c or other languages easily. I can take some time to try it later... And, I think the author of PR [1] and [2] may also need to pay attention to it. [1] https://github.com/apache/incubator-iotdb/pull/415 [2] https://github.com/apache/incubator-iotdb/pull/444 Best, ----------------------------------- Xiangdong Huang School of Software, Tsinghua University 黄向东 清华大学 软件学院 Christofer Dutz <[email protected]> 于2019年10月17日周四 下午4:40写道: > Hi all, > > And by the way ... today a new Thrift version was released ... it fixed > some issues we were having with Thrift & Boost ... > Not sure if they apply if you only want to build the thrift compiler (But > I guess you also need the library) > > I just updated the PLC4X build in a PR and it worked perfectly. > > Chris > > Am 16.10.19, 18:27 schrieb "Christofer Dutz" <[email protected]>: > > Hi Xiangdong, > > Depending on what parts you are using it might be a bit more. > > In PLC4X I setup a groovy script which checks if everything is in place > > https://github.com/apache/plc4x/blob/develop/src/main/script/prerequisiteCheck.groovy > > But we don't have a dependency on the Thrift executable as this is > built as part of our build. > https://github.com/apache/plc4x/tree/develop/tools/thrift > > The reason for this is that this is the only way we can ensure the > Thrift version executed and > hereby for which the code is generated also matches the Thrift version > used in the dependencies. > > In contrast to the Java world, in the C world we had a lot of problems > with for example old bison versions which are typically installed on Macs > > If you decided to use thrift and C++ stuff in your project I would > strongly suggest to also put similar safeguards in place. > > But I would suggest to discuss this with the project (On the list), > before merging it to master. > > Chris > > > Am 16.10.19, 17:47 schrieb "Xiangdong Huang" <[email protected]>: > > Well, I have to put the work aside temporarily because I do not > know how to > write the CMakeList.txt now... > I thought that if I have installed CMake and Thrift well, I just > need to > run something like `g++ -o something.cpp -lthrift` in [1] ... > I was too young to naive... > > [1] > > https://github.com/apache/incubator-iotdb/pull/415/files#diff-2bf8bbbfa32bdb4567f25fcef92e6655 > > Best, > ----------------------------------- > Xiangdong Huang > School of Software, Tsinghua University > > 黄向东 > 清华大学 软件学院 > > > Christofer Dutz <[email protected]> 于2019年10月16日周三 > 下午5:25写道: > > > Hi Xiangdong, > > > > glad you like it, however I would suggest to caution. > > > > While it is possible to do it as we did, it does come with a > downside (As > > probably all multi-language projects know). > > It increases complexity of the build and it increases the > complexity of > > setting up the development environment and it increases the > build time. > > > > We set up quite a bit of tooling to keep the users from > stumbling into > > unwanted pits, but still the plc4x community is considering the > current > > build to be too complex. > > > > So I am happy to help you with this, but I would like you to > think about > > the implications and discuss them in the community first. > > > > > > Chris > > > > > > Am 16.10.19, 11:16 schrieb "Xiangdong Huang" <[email protected] > >: > > > > Hi, > > > > I read how plc4x organizes the modules and pom files. It is > awesome > > that > > using maven to build a so complex project (with many > subprojects...). > > > > I'd like to organize IoTDB thrift codes like: > > > > ``` > > service-rpc/ > > ├── pom.xml > > ├── rpc4cpp > > │ └── pom.xml > > ├── rpc4java > > │ └── pom.xml > > ├── src > > │ └── main > > │ └── thrift > > │ └── rpc.thrift > > └── target > > ``` > > > > The organize is quite like plc-tools module. The difference > is that, I > > want > > to put the generated codes (defined by > > service-rpc/src/main/thrift/rpc.thrift and automatically > generated by > > plugin in the service-rpc/pom.xml) into rpc4cpp/target, > > rpc4java/target. > > > > Then, when compiling rpc4cpp module according to > rpc4cpp/pom.xml, > > maven > > download cmake and some other binaries to compile the codes > under the > > rpc4cpp/target. > > > > I think maybe I can follow how plc4x using Maven to compile > CPP codes > > automatically, and will try it these days. > > > > Best, > > ----------------------------------- > > Xiangdong Huang > > School of Software, Tsinghua University > > > > 黄向东 > > 清华大学 软件学院 > > > > > > Xiangdong Huang <[email protected]> 于2019年10月13日周日 > 上午8:07写道: > > > > > Hi Chris, > > > > > > Of course I want to compile the generated codes... Please > give us > > help. :D > > > > > > Best, > > > ----------------------------------- > > > Xiangdong Huang > > > School of Software, Tsinghua University > > > > > > 黄向东 > > > 清华大学 软件学院 > > > > > > > > > Christofer Dutz <[email protected]> > 于2019年10月12日周六 下午5:06写道: > > > > > >> Well it generates the api, but doesn't build it as a > module, > > correct? > > >> > > >> Was not referring to if you wanted to also compile the > generated > > stuff. > > >> > > >> Chris > > >> > > >> Holen Sie sich Outlook für Android<https://aka.ms/ghei36> > > >> > > >> ________________________________ > > >> From: Xiangdong Huang <[email protected]> > > >> Sent: Saturday, October 12, 2019 9:07:47 AM > > >> To: [email protected] <[email protected]> > > >> Subject: Re: More programming language APIs generated by > Thrift > > >> > > >> Hi Chris, > > >> > > >> I have used maven plugin to generate these language apis > in [1]. > > Are there > > >> some other suggestions? > > >> > > >> [1] https://github.com/apache/incubator-iotdb/pull/445 > > >> > > >> Best, > > >> ----------------------------------- > > >> Xiangdong Huang > > >> School of Software, Tsinghua University > > >> > > >> 黄向东 > > >> 清华大学 软件学院 > > >> > > >> > > >> Christofer Dutz <[email protected]> > 于2019年10月11日周五 > > 下午3:59写道: > > >> > > >> > Hi all, > > >> > > > >> > having done all the Thrift compilation stuff for PLC4X > I guess I > > might > > >> be > > >> > able to help here. > > >> > > > >> > Chris > > >> > > > >> > Am 11.10.19, 09:17 schrieb "Xiangdong Huang" < > [email protected] > > >: > > >> > > > >> > Hi, > > >> > > > >> > I notice there are some PRs [2][3] for generating > CPP, python > > apis > > >> by > > >> > using > > >> > thrift. > > >> > > > >> > Actually it can be compiled automatically by Maven. > > >> > > > >> > Chris introduced a maven-thrift-plugin several > months ago. > > And, just > > >> > modifying the configuration can archive that.. > > >> > > > >> > Using PR [1], we can generate cpp, python, and go > apis under > > >> > server-rpc/target/generated-sources-{language}. > > >> > > > >> > For other PRs, maybe you just need to write > examples about > > how to > > >> use > > >> > these > > >> > api... (and some docs?) > > >> > > > >> > > > >> > [1] > https://github.com/apache/incubator-iotdb/pull/445 > > >> > [2] > https://github.com/apache/incubator-iotdb/pull/444 > > >> > [3] > https://github.com/apache/incubator-iotdb/pull/415 > > >> > > > >> > Best, > > >> > ----------------------------------- > > >> > Xiangdong Huang > > >> > School of Software, Tsinghua University > > >> > > > >> > 黄向东 > > >> > 清华大学 软件学院 > > >> > > > >> > > > >> > > > >> > > > > > > > > > > > > > >
