[ https://issues.apache.org/jira/browse/THRIFT-599?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Roger Meier updated THRIFT-599: ------------------------------- Attachment: THRIFT-599_term-to-any.patch Thank's Anthony! would be great if Thrift not depend on latest greatest Erlang version, if it is not really required. One thing was missing within your patch... lib/erl/include/thrift_protocol_behaviour.hrl failed to compile. I just added a new patch: [^THRIFT-599_term-to-any.patch] builds just fine: http://www.bufferoverflow.ch/hudson/job/Thrift/58/default/ The only thing I miss with erlang target is something like a make test target ;-) However I just started learning a new programming language ... why not! > Don't use unnecessary processes in the Erlang transports and clients > -------------------------------------------------------------------- > > Key: THRIFT-599 > URL: https://issues.apache.org/jira/browse/THRIFT-599 > Project: Thrift > Issue Type: Improvement > Components: Erlang - Library > Reporter: David Reiss > Assignee: David Reiss > Fix For: 0.5 > > Attachments: erlang-refactor-v1.patch, term_to_any.patch, > thrift-599.patch, THRIFT-599_term-to-any.patch > > > The Erlang library currently spawns a process for every buffered/framed/http > transport and every client. These processes can be eliminated by by making > client, protocol, and transport operations work like operations on Erlang's > persistent data structures (like dict): every mutating call returns the new > version of the object. This has four benefits. > - Easier debugging: single stepping into a gen_server:call is very difficult. > - Better error messages: problems that occur during Thrift operations are > localized to a single process, providing a better stack trace and eliminating > uninformative crash reports. > - More measurable performance: time spent in Thrift client operations will > show up in etop under the process making the call, rather than in a transient > client or transport process. > - Better performance: I haven't actually measured this, but I'm pretty sure > that eliminating the extra spawns and messages will speed things up. > The only user-visible changes are to the client. Every thrift call now > returns {NewClient, Result} instead of just Result. > I'm attaching a big monolithic patch, but a fairly readable chronology of my > changes is at > <http://gitweb.thrift-rpc.org/?p=thrift.git;a=log;h=refs/heads/pri/dreiss/erl-refactor;hb=HEAD>. > I'm open to opinions as to whether this should be committed as one rev or > many. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.