Uploaded image for project: 'Thrift'
  1. Thrift
  2. THRIFT-3581

Pure Java build of the Thrift compiler using NestedVM [WIP]

    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Closed
    • Minor
    • Resolution: Auto Closed
    • None
    • None
    • Compiler (General)
    • None

    Description

      I've developed a build process for building the Thrift compiler as a JAR file that can be run on a JVM and requires no dependencies by cross-compiling the executable with NestedVM.

      I think this could be use for the following, among other things:

      1) Building Thrift plugins for IDEs written in Java
      2) Integration into Java build tools like Ant and Maven
      3) Calling the compiler from a Java program when the host platform is unknown

      Also, I see this as providing a way to potentially allow people to create third party "plugins" for the compiler... Java and the plethora of JVM language available might make creating new generators much more approachable for people not comfortable with C++... and also in Java it is not complicated to load code dynamically based on a class name as long as it is on the classpath.

      In any case, I have a working prototype, but it is far from battle tested.

      For the inpatient, I'm attaching a snapshot build to this ticket, but you can also find the source and build instructions here:

      https://github.com/bgould/thrift/tree/nestedvm/contrib/nestedvm

      Will open a pull request when I feel all of the wrinkles have been ironed out (it is close, and quite usuable already) to see if it might be appropriate to bring this into the contrib/ folder, or even include as an artifact in the Maven repos for a future release.

      Attachments

        1. thrift-compiler-0.9.4-SNAPSHOT.jar
          6.64 MB
          Benjamin Gould
        2. thrift-compiler-0.9.4-SNAPSHOT-sources.jar
          61 kB
          Benjamin Gould

        Activity

          People

            bcg Benjamin Gould
            bcg Benjamin Gould
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: