On Jan 30, 2009, at 4:18 PM, David Reiss wrote:
Did anything ever come of this?
I haven't heard any news. I think a "seems to work for me, but who
knows"-quality
patch was sent to the old Facebook-hosted list way back when. If
you want it,
I can try to dig it out for you.
The post that I cited was sent in Nov. 2008 to this list by Mark Slee.
I believe you are thinking of the patch that Norman Casagrande
submitted. My original question was posted to the Facebook-hosted list.
If we do the port ourselves, then it might be useful to have the patch
that was submitted, just so we can look at it and see what was
modified. I'm still holding out hope that the November 2008 work
actually came to something usable.
My project has reached the point that we need a C++ implementation of
the Thrift library that works in Windows. Before we go off and do
something ourselves, it seemed prudent to come back once again and
ask
whether anyone else is working on this, and whether they would be
willing to share. We can contribute someone to work on it.
If we need to do it for ourselves, we would probably take the route
suggested by Norman Casagrande, replacing all of the Unix-specific
code with Boost ASIO or other Boost code as necessary.
If all you need is the client, then the only class you should need
to port is
TSocket. If you need a Thrift server too, then yes, you'll probably
need
TServerSocket and some of the concurrency stuff. libevent appears
to work
on Windows, so ASIO shouldn't be necessary.
If you are interested in merging your port into the Thrift trunk, I
think
following these steps would help a lot:
1/ Don't make wholesale changes to TSocket. If you need to do a
rewrite,
please do it as a new class. There is no harm having a TWinSocket
class
in the tree. If it ends up being TBoostSocket, that's fine too, as
long
as the differences with TSocket are clear. Same with TServerSocket.
2/ The concurrency code was designed to be implementation-neutral, so
it should be possible to swap out pthreads without any changes to
existing
code. If you need to make changes to an existing concurrency class,
please
bring it up with this list as early as possible.
Best of luck!
--David
Thank you very much for this information and advice. We definitely
need the server as well as the client. If we end up doing the port,
then we would certainly be willing to contribute it. We'll also
discuss our plans and goals with you before we start to see how they
line up with others. Thrift has been very beneficial to us and we'd
like to return the favor.
- Rush