8

I am thinking of writing customized torrent client in ruby. I found the following libraries (which are pretty old as Matt pointed out bellow). However i would like to hear about any library that i might have missed and i would love to hear what the community have to say about the following libraries. As in pros and cons...

Please note that i am hoping to modify some inner workings of the library to suit my needs. Hence a pure ruby library would be ideal.

Note: I searched stackoverflow for this question (or anything similar). The only questions that came up were asked long ago and didn't have any decent answers. Hence this new question.

Thanks for your time!

Community
  • 1
  • 1
thekindofme
  • 3,846
  • 26
  • 29
  • Both of those projects are 5+ years old... – Matt Ball May 24 '11 at 13:58
  • I know, its hopeless. There should be something out there thats maintained... right? – thekindofme May 24 '11 at 14:12
  • I guess there just isn't the demand for a Ruby implementation. – Matt Ball May 24 '11 at 14:13
  • You may as well provide a link from this question to those questions, so that people who come across the old questions will know about this question (links get displayed both ways). – Andrew Grimm May 24 '11 at 23:11
  • added a link to the old question – thekindofme May 25 '11 at 01:12
  • Any new information about this question? – fguillen Aug 18 '12 at 09:06
  • @fguillen nope i've given up on it for the time being. but please do update up if you come across anything. – thekindofme Dec 05 '12 at 08:56
  • 1
    @thekindofme at the end I implemented a Ruby Wrapper for the Transmission API as you can see in my answer, at the end I think is better than a native Ruby bitttorrent implementation because I don't think any Ruby implementation was gonna be as active development as this bittorrent client. But I understand it is not covering your particular needs as you explain in your question. – fguillen Dec 05 '12 at 14:23

2 Answers2

3

After not finding any good solution to connect my ruby code to a BitTorrent protocol I have implemented a Ruby wrapper for the Transmission RPC API:

It is a very simple version that works for my needs.

Of course it has a very big dependency of a Transmission client running for it, but I think it is a dependency you want to have due it is a very stable and very updated bittorrent client.

I recommend to set up a headless transmission daemon

fguillen
  • 36,125
  • 23
  • 149
  • 210
  • @AbeVoelker it is the one I'm using in my desktop and it works like a charm, also I see the developers are very focused in simplicity and I like that. Anyhow I should check _rtorrent_ too. – fguillen Dec 05 '12 at 17:22
  • @fguillen this is pretty neat. and you should checkout rtorrent. its one of the fastest and most stable clients out there. I think it already have many APIs in several languages including ruby. so you might want to check those out as well. ex: https://github.com/mcmorgan/retort – thekindofme Dec 06 '12 at 02:41
1

You have a few alternatives, rolling your own with FFI and any c/c++/java torrent library, or use a well known torrent daemon (ie: transmission, utorrent, etc) and talk to it via its rpc interface.

Pablo Castellazzi
  • 4,164
  • 23
  • 20