Fred, it may be the Java however, I've been able to poke at the server 
successfully with python ... that's why I suspected the Obj-C.

-Jeremy




________________________________
From: Fred Potter <[email protected]>
To: [email protected]
Sent: Mon, April 19, 2010 10:18:18 AM
Subject: Re: Using the cocoa source generator.

Hi Jeremy,

It sounds like it _could_ be an issue w/ the Java side.  Are the log4j
libraries there?  The slf4j-api-1.5.8.jar and slf4j-simple-1.5.8.jar
files are working for me.

You might want to try testing the Java server in isolation.  If you
generate the python output for your .thrift file, you'll also get a
shell script which you can use to poke at a running thrift service.
That should help you troubleshoot.

Fred

On Mon, Apr 19, 2010 at 8:25 AM, Jeremy Fergason
<[email protected]> wrote:
> All,
>
> I've been trying to get a simple demo going using the Objective-C/Cocoa code 
> generation.  I've been able to get it to work with both Java and Python; and 
> I think that I'm fairly close with Objective-C.  I went ahead and turned the 
> Objective-C stuff into a framework (I'd be happy to commit this back when 
> everything is working) ... this was relatively straightforward, just required 
> changing the imports on the generated code to be:
>
> #import <Thrift/...>
>
> I also had some issues including the CFNetwork/CFSocket... headers.  I think 
> this is because you want to include that on the iPhone but not MacOSX, for 
> MacOSX I think you should just include the CoreServices stuff.  I also added 
> the delegate for the NSInputStream and NSOutputStream.
>
> Everything is compiling and running now; however, I can't actually get the 
> service to work.  I have a java server running on port 7911 and it appears to 
> be getting something because everytime I try to communicate via objective-c I 
> get an error about Log4j appenders not being configured properly.  In 
> objective-c I get an error about the pipe being broken.
>
> I've posted my code online:
>
> Thrift Framework: http://clement.corwynn.com/ThriftCocoaFramework.zip
> Thrift Demo code: http://clement.corwynn.com/ThriftTutorial.zip
>
> Thanks for any insights in advance!
>
> -Jeremy Fergason
>

Reply via email to