Results 1 to 7 of 7

Thread: Thrift?

  1. #1

    Default Thrift?

    Hi all,

    Are there any plans to offer functionality to interact via Apache Thrift? Has anyone here used Spring Integration with Thrift, perhaps over AMQP? I'd be very grateful to hear about any such experiences.

  2. #2
    Join Date
    Jan 2008
    Location
    Mohnton, PA USA (that's near Philadelphia)
    Posts
    2,148

    Default

    I've never heard of Apache THrift, but looking at it now it seems like there is not much or anything that needs to be done. The way I understand it Apache Thrift will generate client code fo you in the language of your choice and Java is one of them. So once the Apache Thrift RPC code is generated you can simply invoke it using Service Activator. For example:
    Code:
    <int:service-activator input-channel="inChannel" . . .>
          <bean class="foo.bar.MyThriftClient"/>
    </int:service-activator>
    Is that what you were looking for

  3. #3
    Join Date
    Oct 2005
    Location
    Boston, MA
    Posts
    2,853

    Default

    Actually, I have considered Thrift support for a while, and we could probably add implementations of our Serializer/Deserializer strategies at first. It might even be a candidate for inclusion in the "data-commons" module rather than spring-integration itself. One issue is that the model is generally coupled to the generated classes, and that's something that we can't handle generically, of course.

    Can you explain a bit more about what you have in mind for your particular use-cases?

    Thanks,
    Mark

  4. #4

    Default

    Hi,

    Thanks for your replies.

    I'm afraid I don't really have any hard-and-fast requirements. I've been playing with Spring Integration and AMQP recently, but have been asked at work to implement a set of systems that communicate via Apache Thrift, which I know little about.

    It appears to me that Thrift solves two problems - intermediate data representation, and client/server stubbing. It's weakness as I understand it is that it's a point-to-point communications system between two known points, increasing coupling and not allowing for things like publish/subscribe models. This could be overcome by sandwiching a messaging system between Thrift endpoints, but this seems like a bloated solution.

    Have I misunderstood Thrift? I'm thinking some kind of Thrift serialization adapters/transformers for Spring Integration would be a benefit to some.

  5. #5
    Join Date
    Aug 2005
    Location
    Atlanta
    Posts
    124

    Default

    Hi,

    When thinking about supporting Apache Thrift we may also look at supporting other common protocols as well:




    Cheers,

    Gunnar
    Gunnar Hillert
    SpringSource/VMWare, Spring Integration team
    SpringSource Team - Spring Training, Consulting, and Support - "From the Source"
    http://twitter.com/ghillert
    http://blog.hillert.com/
    http://blog.springsource.com/author/ghillert/

  6. #6

    Default

    Hi,

    Does the current version of Spring support Apache Thrift? I want to run Thrist server inside my Jetty container.

    Thanks.

    Regards,
    Rakesh

  7. #7
    Join Date
    Mar 2010
    Location
    Gtr Philadelphia, PA
    Posts
    2,146

    Default

    There is not currently any built-in support but, as Mark said last year, we'd like to get support into the framework at some point.

    That said, it's easy to write your own POJO that can use any technology (such as Thrift) and simply drop it into a Spring Integration as a <transformer/>, <service-activator/> etc.

    If you'd be interested in contributing something, we'd be happy to take a look... https://github.com/SpringSource/spri...ONTRIBUTING.md
    Gary P. Russell
    Spring Integration Team
    SpringSource, a division of VMware

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •