[ 
https://issues.apache.org/jira/browse/THRIFT-2835?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15364465#comment-15364465
 ] 

ASF GitHub Bot commented on THRIFT-2835:
----------------------------------------

GitHub user dtmuller opened a pull request:

    https://github.com/apache/thrift/pull/1039

    THRIFT-2835 Add possibility to distribute generators separately

    I rebased the original pull request #368 from @nsuke and added a few fixes 
on top of that.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/dtmuller/thrift THRIFT-2835

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/thrift/pull/1039.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #1039
    
----
commit 8642a320ce71fd50495582041be898f2e149e743
Author: dtmuller <[email protected]>
Date:   2015-05-08T15:46:03Z

    THRIFT-2835 Add possibility to distribute generators separately from thrift 
core, and load them dynamically

commit 333278a51aa42eca6adbc703a30ce1c15c9bee36
Author: dtmuller <[email protected]>
Date:   2016-07-06T15:12:23Z

    Fix constness

commit 64bbcd6d97d4dc1cc5e36787497190785d827f00
Author: dtmuller <[email protected]>
Date:   2016-07-06T15:13:41Z

    Fix build files

commit 65943df4190edf5e60338d5c2630cf2664b05601
Author: dtmuller <[email protected]>
Date:   2016-07-06T15:15:39Z

    Type "wb" may not be supported by popen on non-Windows platforms

commit 73e5d8dafbdb8a7d4ce421a4009113296d54220f
Author: dtmuller <[email protected]>
Date:   2016-07-06T15:16:15Z

    Don't clear type cache with every t_program conversion
    
    Doing so breaks cache for recursive runs due to thrift includes.

commit e22790e0f0f0fd6c00161171fbb7508ede942beb
Author: dtmuller <[email protected]>
Date:   2016-07-06T15:16:59Z

    Fix unit test test_const_value
    
    If t_const_value is map type we cannot rely on the map ordering as the map
    key is of pointer type.

----


> Add possibility to distribute generators separately from thrift core, and 
> load them dynamically
> -----------------------------------------------------------------------------------------------
>
>                 Key: THRIFT-2835
>                 URL: https://issues.apache.org/jira/browse/THRIFT-2835
>             Project: Thrift
>          Issue Type: New Feature
>          Components: Compiler (General)
>            Reporter: Anatol Pomozov
>              Labels: fbthrift
>
> It is a follow-up for discussion with Facebook's fbthrift 
> https://github.com/facebook/fbthrift/issues/48
> fbthrift adds its own generator that creates C++ classes based on their 
> libraries. I do not know how upstreamable this generator but I think other 
> companies would want to do the same - create their own custom generators.
> Currently there is no way to distribute generators separately from the thrift 
> core. Thus the company have to fork whole project and add their own 
> generator. It is what Facebook did.
> The idea is that thrift should be able to load language generators 
> dynamically. i.e. a company foo creates its own generator and puts it to 
> system /usr/lib/thrift/generators/cpp_foo.so When thrift compiler starts - it 
> checks /usr/lib/thrift/generators/ and uses dlopen() to load the shared 
> libraries. The shared library contains information about the generator (name, 
> options, ...) thus it allows thrift core to use this custom third-party 
> generator.
> This allows companies to create and distribute generator will less pain and 
> no need to fork the project.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to