The Source for Java Technology Collaboration
User: Password:



Tim Boudreau

Tim Boudreau's Blog

Should there be a "codeforager.org"?

Posted by timboudreau on April 05, 2005 at 08:53 PM | Comments (13)

(pictures in the blog are from Grenoble, France, where I spent last week helping some folks with NetBeans module projects)

A few months ago, I had an idea to write a newsreader plugin for NetBeans. So I looked around for a handy JavaMail NNTP provider. There was one out there, part of a project called Knife, which pointed me at ClasspathX, where I downloaded the sources, tried to build it (building Java with Make...ick), found I needed another library...which needed another library...and the whole thing seemed to be set up to cause maximum pain to anyone trying to just build with a standard Sun JDK - after all, I wasn't setting out to redistribute, just to test my code.

alps2.JPG

Anyway, distractions leading to distractions, I remembered that a defunct Mozilla project, Grendel, contained an NNTP provider - and plus it would be semi-license compatible with NetBeans.

So I checked out the source for Grendel, and put some work into splitting out the NNTP pieces. It's old code (pre-Collections), but basically sound, and written by some fairly respectable folks like Jamie Zawinski.

So in my spare time, I've got it working, added support for posting, written a ton of JUnit tests for it. Not finished, but I'd like to contribute it somewhere.

But the point is - how many other dead projects, open or closed source, out there, contain good code, if it were just librarified? I'd love to see a site for such things, and encouraging people to do this sort of task, providing guidelines and a place for them to live. The guts and glory might be in writing something from scratch - most developers prefer to, for better or worse. But there would be tremendous value in "liberating" some of the nifty and valuable things that are out there.

SunOffice.JPG
Who wouldn't want to work in an office with this view?!

Bookmark blog post: del.icio.us del.icio.us Digg Digg DZone DZone Furl Furl Reddit Reddit
Comments
Comments are listed in date ascending order (oldest first) | Post Comment

  • A very good idea Tim. It'd be great to see the good old "Software Reuse" maxims put to work there. And, btw, fantastic snaps! I' work for free at such an office :p

    Posted by: bharathch on April 05, 2005 at 10:56 PM

  • Sun's campus in Grenoble is very nice indeed. Besides, there are other companies and schools around. It must be a great place to work in :)

    Posted by: gfx on April 06, 2005 at 01:52 AM

  • Oh and next time you come in France, just let us now :) See, I work for a computing magazine which published hundreds of articles about Java and I live not far from Grenoble. I would have loved to meet you for an interview.

    Posted by: gfx on April 06, 2005 at 01:56 AM

  • Yeah, Sun's Grenoble campus is beautiful. I interviewed there once, just before the dot-com bust. :-(

    Posted by: armhold on April 06, 2005 at 03:16 AM

  • Yes, there should be a codeforager.org. It would be useful to rediscover small libraries and clean them up for reuse. A number of projects, even live ones, have great features which arguably should be extracted. It seems like a form of community refactoring and re-purposing.

    Your blog raises other questions, though. What about licensing? Seems you have to respect the original license, unless you just use the code as inspiration. Will licensing affect your codeforager hosting effort? Then, is the goal to build libraries, or utility classes, or sample code? For example, I often forget the exact sequence of calls to get a Document instance from XML I have in some input format. Having that written down seems less like a library or even a utility class, and more like a little note. So where do helpful samples go? Are you only focused on libraries?

    Last thought--others might argue that if the project isn't dead yet, refactoring for your own purposes is poor form--you should probably contribute to the live effort. But on the other hand, if it's no longer maintained, it seems like a great way to continue forward movement.

    Good idea. Let us know if you follow up on it.

    Posted by: pdoubleya on April 07, 2005 at 05:50 AM

  • How about posting your code to a new website from Apache: http://www.codezoo.net/

    Posted by: shahzad on April 07, 2005 at 06:53 AM

  • for open source, what's wrong with sourceforge?

    Posted by: eitan on April 07, 2005 at 07:40 AM

  • actually, I smell a blog entry (remind me someday to write it up if nobody else does)... a CPAN for java.

    If you java app doesn't have x.z.y.FooClass, but that class is registered with the CJAN archine, (but the code imports it), the VM could download it from the master archive. It'd make life so easy on many levels for deployment AND development.

    In fact, Java is ideal for this, since it already has the ability to dynamically download and run signed code. It'd just have to be tied into the VM by default somehow.

    Posted by: mason on April 07, 2005 at 08:08 AM

  • Well, in the case of the Grendel stuff, the Mozilla organization owns the code, so it's more their decision than mine - though I'm guessing they wouldn't care too much.

    Re sourceforge: Yeah, that's an option. So is Java.net (in either case, though the Mozilla license doesn't require it, I think, the honorable thing to do is to give them first crack at it). But there's the larger issue of creating a site that encourages the morphing of code from dead projects into small libraries that do one thing well. That's kind of a set of values that are to be encouraged, and just creating a Sourceforge project doesn't do that - it's the lazy way out.

    Re codezoo, that might work - but some of the things I can imagine are pretty small and don't fit into any of the categories terribly well (for example, I recently librarified something that just provides a handy interface to NIO memory mapped files - where would that link from? Or collections-like implementations of dynamic primitive int arrays?).

    I like the "CPAN for Java" idea - that's about what I was thinking of. What was that quote from Donald Knuth about reuse-in-the-small being a well solved problem?

    Posted by: timboudreau on April 07, 2005 at 08:34 AM

  • First, great pix. Commute might be interesting if you live on the wrong side of the mountain! ;)

    Also, great idea. We've talked about that type of facility for java.net. As you can imagine, projects either get orphaned or don't get off the ground for one reason or another all of the time. Sometimes there are people with roles in the project, but the project owner has abandoned it. Other times it's abandoned but it's based on a good idea and might be the beginnings of some useful code.

    We found that one of the advantages of java.net having Community Leaders is that there is a person/people who can identify these dormant or dead projects and assess what to do with them.

    Of course, the "what to do" is an ongoing discussion. On thing we've discussed is putting projects up for adoption to find a new project owner. In other cases, if there are some "parts" that are of interest, to put them in a "parts" area. I had actually created a "JavaJAR" area on java.net for such parts, but I don't think the idea got adopted.

    We definitely could find a home for some of that stuff on java.net if there are artifacts of interest. The real question is how to organize it and make it easily searchable. We could use a wiki for some of this.

    Posted by: jbob on April 07, 2005 at 02:34 PM

  • Yep, thats why I registered agilereuse.org, but currently have no time to work on it.

    My other sites are testdriven.com and richclients.org

    -david

    Posted by: dvydra on April 07, 2005 at 06:38 PM

  • Good idea about a code repository. Reminds me of hunting for car parts in auto junkyards. What's interesting is that parts can be readily reused in other technologies, such as car parts and electronic components, but in software we haven't reached the level of agreement necessary to make this commonplace. We'll hack code out of one system, then we'll hard-wire it into our own system, creating another piece of unique code that can't travel from system to system. We're not reusing, we're re-hacking. It's a matter of clearly defining the boundaries of code components, which is not so easy in the current model of programming. I get into this in a recent blog post.

    Posted by: napier on April 14, 2005 at 12:57 PM

  • Regarding Classpath-X: you definitely want to talk to dog on #classpath on irc.freenode.org. Chris is the author of GNU inetlib and large chunks of GNU JAXP. The NNTP provider is now part of GNU inetlib. See http://www.gnu.org/software/classpath/inetlib.html for details. Good luck for the next try, the practical reason we use make for code in GNU Classpath is portability (make just runs anywhere without introducing a dependency on a JVM) and bootstrappability (it's pointless to require ant if you are the only runtime available on a system) on java-less systems.
    cheers,
    dalibor topic

    Posted by: robilad on April 17, 2005 at 11:15 AM





Powered by
Movable Type 3.01D
 Feed java.net RSS Feeds