login

RubyGems (Ruby)

HomePage | RecentChanges | Preferences | Wikis | RubyGarden | Feed-icon-16x16

This page contains changes that are awaiting review.
RubyGems is a new approach to managing packages of Ruby code. The most convenient feature for the average user is that gems (apps and/or libs) can be downloaded and installed in one step from the command-line. For example, this command downloads and installs 'log4r'.
  gem install log4r
Any other gems that log4r depends on will be grabbed as well. Anyway, RubyGems has its own Wiki, which you can browse at HTTP://rubygems.rubyforge.org. It includes a brief overview as well as detailed information. The current status (2004-04-26) is still very much alpha, but very much working. Note: The living, breathing RubyGems has been in development since October 2003 or so. Prior to that, another project of the same name and the same goals was in operation, but it has petered out. The text below concerns the old RubyGems, and is left here for posterity.
For those wondering, I have returned from my Ruby hiatus and intend to lend whatever support I can to the new RubyGems project, including reviving some of my original concepts if they have been lost to the new developers. The original RubyGems petered out 2 years ago mostly because of the large amount of new code it required, much of which is now supplied in the default Ruby installation. With this new support, I think the new RubyGems can finally become what I originally envisioned. -- RyanLeavengood
  OLD RUBYGEMS MATERIAL BELOW!

RubyGems is a system that aims to provide the following (it is still in development): Other general features of the system include: I expect to release RubyGems 0.5 in early October 2001. This version will only include the core features mentioned in the first two bullets above (developer tools to create gems files and user tools 1000 to read and use them.) --RyanLeavengood
''Sounds fantastic! I like the idea of one gem specifying that it requires another. I can imagine the peer-to-peer system installing one gem and then finding and installing the gems that it needs, and so on, without any extra intervention from the user. Could the metadata be extensible so that gems could be the basis for the component models of different frameworks? Sort of a COM layer for Ruby, through which higher-level frameworks could locate, load, instantiate and interconnect components based upon framework-specific metadata. E.g. a web browser could look for gems that display different MIME types, a naming service could look for gems that talk different directory protocols, and so on.'' --NatPryce
Yes, similar to the Debian package system I intend for the P2P system to automatically resolve dependencies between gems. Regarding extensible metadata, yes I think that is also a great idea. After some discussion with our friend PragDave, I have decided to support multiple file types (simple text and binary to start with), and in the process will also support extensible metadata in these file types. Everything you mention is very interesting and something I will definitely keep in mind as I continue developing RubyGems. --RyanLeavengood
''Have you considered how much of the P2P system is preestablished infrastructure and how much is configured ad-hoc? Ad-hoc p2p networks present a number of problem that are not easily solved. TMN, no adhoc p2p network has been proven stable and scalable in practice.''
You make a good point. My thoughts were to just leverage the P2P technologies to provide a common interface for services related to RubyGems. I never thought a purely ad hoc P2P network would be very good for providing consistant access to all the gem files that have been released (for the reasons you mention.) Instead I envisioned a ring of "Master Peers" (preestablished infrastructure I suppose) that would each contain all the released gem files. This allows for a more scalable and stable architecture that essentially has built-in load balancing and mirroring. Any additional peers that join up and choose to provide the RubyGems Content Provider Service (or whatever it is called), will just act as additional file sources that might allow for quicker downloads to certain other peers based on network topology or load, etc. Also, as I mention above, there is a need for "trusted servers" that can provide MD5 checksums for all the released RubyGems files. The "Master Peers" mentioned above could also provide this service. For security reasons, only peers in a certain peer group could provide these Master Peer security services, and all peers that choose to join this peer group would need to be validated and approved before they can join. These concepts of peer groups and peer group services have come from my studies into the JXTA (HTTP://www.jxta.org) framework (though I doubt that the concepts are unique to JXTA.) Of course given how young this technology is, it is hard to say whether any of the above will really work, or how secure the final system will be. At this point my plan is to look into prototyping a Ruby implementation of the basic JXTA protocols, and start experimenting. If it turns out that none of the above plans are feasible, a more standard client/server architecture could be designed and put on top of RubyGems, just as I plan with this P2P system. Nothing about the core RubyGems system makes either of these favorable over the other. I just think P2P is an interesting new technology that could produce a very advanced system for Ruby library distribution. --RyanLeavengood
This all sounds very interesting. Clearly progress could be made on both the "how gems are sourced" strategy and the other areas such as the meta-architecture, local install issues, etc, in parallel. RustyF
From the description above, it is un 4c3 clear (to me) if the system includes the CRITICAL feature of library versioning. Without library versioning, tracking dependencies does not work in practice - the system will be continually unstable. A version number can be based on the following parts (all of which should be set in a dependency request): Without versioning support, you'll get breakage in applications (and other libraries) whenever somebody update a library. (You should also note that just about any application might be used as a library, so...) --EivindEklund
There is a RubyGemsToDoList for people to beat into shape to assist progress towards integration into Ruby 1.8.4.
oh my god, an other packageing system.. why not simply use dpkg or rpm?
If they are available for your system, go ahead and use them. If not, then gems is a good option.

HomePage | RecentChanges | Preferences | Wikis | RubyGarden
Edit text of this page | View other revisions
Rev 91, Last edited at March 30, 2008 18:27 pm by anonymous / none (diff)
Find: