iago icon indicating copy to clipboard operation
iago copied to clipboard

Iago doesn't build under Windows

Open jwaldrop opened this issue 12 years ago • 12 comments

The issue is that the maven-finagle-thrift-plugin doesn't ship a Windows thrift executable, so the thrift bindings are impossible to generate (the error message is a very unhelpful NPE in plexus-utils trying to copy the binary out of the jar).

The work-around issue for Iago is to ship a separate thrift dependency that doesn't require people to generate thrift bindings on Windows.

jwaldrop avatar Jun 27 '12 15:06 jwaldrop

How about we just fix maven-finagle-thrift-plugin or as a work around, force people on windows to have thrift installed already as a pre-req?

caniszczyk avatar Jun 27 '12 15:06 caniszczyk

i have thrift installed and on the path, i get this error.

hsiboy avatar Jun 27 '12 15:06 hsiboy

Yes, the error is not that thrift isn't present, but that thrift isn't in the jar. The plugin attempts to find a thrift.null executable in the jar and needless to say that fails. So, even if people have thrift, the plugin needs to be revved to realize that it's on Windows. Also, the generator needs to be the Finagle generator specifically, since the normal thrift generator doesn't generate async (Future-aware) Java code.

jwaldrop avatar Jun 29 '12 03:06 jwaldrop

I have a partner in crime for building the finagle-ized thrift generator so that we can include it in the plugin. We're worried this may take some time, and I think the project could stand to have the thrift interface separated out anyway, so I'm going to proceed with the workaround for now and then we'll rev the plugin when we have the binaries.

jwaldrop avatar Jun 29 '12 03:06 jwaldrop

"The plugin attempts to find a thrift.null executable in the jar and needless to say that fails." ah, yes, that explains the error message. happy to test the workaround when its available.

hsiboy avatar Jun 29 '12 13:06 hsiboy

I thought of another solution that I like more. We have an open source project called Scrooge that generates Finagle-compatible Scala code from Thrift IDLs. This removes the dependency on native binaries completely... I have a branch that is a WIP which converts to Scrooge.

jwaldrop avatar Jul 05 '12 17:07 jwaldrop

Where can I clone the branch, which solves the Problem? Or is there another solution for the Problem found?

christianhenle avatar Sep 13 '13 07:09 christianhenle

There is no branch that solves this. Solutions include

  1. don't use Windows
  2. fix the maven-finage-thrift-plugin
  3. On a non-windows platform, create a version of Iago that has the generated source, then submit that as a patch.

Hope that helps!

On Fri, Sep 13, 2013 at 12:19 AM, X-Man71 [email protected] wrote:

Where can I clone the branch, which solves the Problem? Or is there another solution for the Problem found?

— Reply to this email directly or view it on GitHubhttps://github.com/twitter/iago/issues/4#issuecomment-24377369 .

WamBamBoozle avatar Sep 13 '13 18:09 WamBamBoozle

Maybe tweak the build to look for the thrift executable on PATH, rather than in the JAR?

apennebaker avatar Feb 06 '14 20:02 apennebaker

We have a fix for this in the works. We're using the scrooge generator. I hope to push this out within the next few work days.

WamBamBoozle avatar Feb 06 '14 21:02 WamBamBoozle

This should be fixed as of

415c7970cce6e3f5569cd2ee8f46d3c91308bf90

waiting for a windows user to verify ...

WamBamBoozle avatar Feb 18 '14 18:02 WamBamBoozle

I think this is resolved by switching to the scrooge generator. We're waiting for some windows user to verify.

On Thu, Feb 6, 2014 at 12:01 PM, apennebaker [email protected]:

Maybe tweak the build to look for the thrift executable on PATH, rather than in the JAR?

Reply to this email directly or view it on GitHubhttps://github.com/twitter/iago/issues/4#issuecomment-34364261 .

WamBamBoozle avatar Feb 18 '14 18:02 WamBamBoozle