Skip to content

Ruby CouchDB Library Comparison

As I looked at some of the Ruby libraries for CouchDB, it was clear that they have very different approaches. In the hopes of keeping them straight I began making a table. I am sharing it for your right-angled pleasure. Warning, it is in beta form. If you post comments, I will try to incorporate your feedback in the table. Thanks!

Last updated on May 6, 2009.

RelaxDB CouchREST CouchFoo DataMapper (DM) Rest Adapter CouchObject Ruby-CouchDB ActiveCouch Coach Potato
Source Code paulcarey on GitHub jchris on GitHub georgepalmer on GitHub

datamapper on GitHub couchobject at RubyForge couchdb at RubyForge activecouch at RubyForge couch_potato on GitHub
Underlying HTTP Library [1] Net::HTTP REST Client ? Net::HTTP ? ? ? REST Client (couchrest is a dependency)
Interface ? ? ActiveRecord style DataMapper style ? Thin wrapper over CouchDB’s RESTful API ActiveRecord style
ORM specific? [2] N ? N ? N ? Y – DataMapper N ? N N ?
Automatic view creation? ? ? ? ? ? ? ? Y
Quality of test suite? ? ? ? ? ? ? ? ?
Do you need to write Javascript? [3] ? ? ? ? ? ? ? Y

Notes:

  1. I personally think Net::HTTP is a bit crufty. I prefer to see other Ruby HTTP libraries, such as HTTParty.
  2. Does a library only works with a particular Object Relational Mapper (ORM)?
  3. Does a library require that you write Javascript? Or does it generate the JS for you automatically? (I am not taking sides on which is better.)

More transparency, fewer lobbyists?

William Eggers, in his book, Government 2.0, writes “We shouldn’t need a lobbyist to navigate our way around government.” (p. 125) I mentioned this quote in a Saturday panel at Government 2.0 Camp session called “Top Ten Measures for Transparency Success.”

This is a powerful sentiment. It resonates because many people believe that lobbyists have become too pervasive and powerful. Thinking about his quotation in the context of a discussion about transparency leads me to ask a more pointed question: As the government becomes more transparent, will lobbying activity decrease?

I don’t have empirical data to present, so let me talk intuitively instead. How would a researcher connect increased levels of transparency with a decreasing level of lobbying activity? I used “decreased lobbying activity” as an intentionally generic term. It might mean fewer lobbyists, fewer lobbying firms, less impact due to lobbying, or some combination.

Let’s drill down a little bit. Here I propose a simple method: compare the roles of lobbyists with some specific benefits of transparency and see what connections jump out. Lobbyists serve many kinds of roles, some more legitimate than others:

  • representing the positions of their affiliated organizations
  • presenting information relevant to their situation
  • trading influence, currying favors
  • using financial means to influence law
  • building relationships and bridges
  • getting insight in the future; e.g. future legislation

How might these lobbying roles connect to transparency? In a previous blog post, I listed the the five benefits of transparency according to Eggers:

  1. Enhance accountability
  2. Increase citizen involvement in government
  3. Raise performance
  4. Boost government credibility
  5. Reduce corruption

In this simple method of looking at connections between lobbying roles and transparency benefits, there are a couple of direct connections that stand out.

(a) The second benefit of transparency, namely having more citizens engaged, has the potential to reduce the impact of special interest lobbyists. The rationale is straightforward: engaged citizens are more likely to contact their lawmakers directly and perhaps even organize. As citizens gain more power the impact of lobbyists will decrease, all other things equal. Examples such as Open for Questions at whitegouse.gov and Change.org illustrate some technology-based platforms for bringing in public opinion.

(b) The fifth benefit of transparency, namely reducing government corruption in general, should also reduce corrupt lobbying behavior. The rationale goes like this: increasing the reporting of lobbying activity brings more public attention. This means that citizens and journalists have the raw data they need to delve deeper, form their own opinions, and raise a stink if they find something objectionable. Resources such as the Influence & Lobbying section of OpenCongress.org were designed with this purpose in mind.

This is far from a systematic analysis, but my thinking so far offers some support that increasing transparency will decrease lobbying activity. There are probably other connections that deserve mentioning. I’d appreciate if you added your thoughts in the comments.

Going beyond the discussion above, it is clear that as long as we have private interests and organizations, there will be a need for advocacy and therefore lobbying. Of course, that lobbying needs to be done responsibly and kept in check.

I spoke with Jeffrey Levy and some other people after the panel. The big picture is that we have 535 elected officials that represent about 306 million people. Getting access to your representatives and sharing information with them in that sense is a big informational challenge. Lobbyists traditionally have served a key role in this dynamic.

Benefits of transparency

I am currently sitting in a panel at Government 2.0 Camp in Washington, DC.  I wanted to highlight something from William Eggers.  In his 2005 book “Government 2.0″ he lists 5 benefits of transparency (pg. 129):

  1. Enhance accountability
  2. Increase citizen involvement in government
  3. Raise performance
  4. Boost government credibility
  5. Reduce corruption

This is just a quick placeholder. I will interconnect these ideas to other policy topics in future posts.

Potomac Hackers meeting 3/25/09 @ 6:30 pm

A DC-area programming group, the Potomac Hackers, is meeting on Wed., March 25 in the DC area. The location will be decided by a vote, please RSVP on the Google Group.

Who are the Potomac Hackers?

We started last year — we were called the Potomac Ruby Hackers back then. To be more inclusive, we dropped the Ruby requirement.  I compiled a few quotes from a previous message board thread.  I think these quotes give us an idea of where we might want to take the group. There is a lot of common ground and some different ideas of things we might try…

  • “Programmers should get together and do more than just listen to a presentation — the typical way to organize a user group. They should have a place to experiment on various projects. This is good for us and it is good for the tech community.”
  • “…we should avoid a one-to-many, scheduled-presentation style
  • affair, but whatever we do should be relatively organic.”
  • “…the most effective method for people to organize and share knowledge and trade ideas is to work together one-to-one, pair programming.”
  • “at the core it should be about programming together. I would truly love the chance to simply get to watch more and learn as I think it would help mold my programming behavior…”
  • “a place to go code where you can be certain that there will be other people coding around you. I don’t think it matters what language they are using.”
  • “If the group provides a place for people to meet and a communication mechanism for people to exchange ideas in advance, then that’s all you need.”
  • “the intent of the group: – Polyglotism – Learning – Sharing – Community – Beginner and advanced friendly alike – Welcoming (I did host PRH in my backyard a few times with — that was part of the point)”
  • “It would be about discussing tech issues — and building consensus to find projects to work on together.”
  • “I know we all have our own individual projects that we want to spend time on, but I feel like if we can come up with something to all work on together that as a group we can product something truly meaningful.”
  • “I believe that human interactions and group dynamics are sorely under- examined and undervalued in our technical community, and that remedying this could have a great beneficial effect on our collective productivity.”
  • “I think many people assume that groups (many-to-many) have to be chaotic, disorderly, and unsatisfying. They don’t.”
  • “My vision for PRH is about building a good group dynamic while doing fun programming stuff. I want to do that with a shared understanding that it will be in a consensus fashion, not a “loudest or most dominant voice wins”.”
  • “when we get there, the organizer makes any announcements, and then we all take 15 minutes or so to mill about and find people with whom to work on things, and then for the rest of time we do that. Ideally it will continue to be organic, so that you can wander around and see what people are doing during the time.”

eDemocracyCamp2

eDemocracyCamp logo

On Sunday, April 19, 2009, those interested in e-democracy will gather at eDemocracyCamp in Washington, DC. Join us.

GSA and a culture of collaboration

I just read a post by Paul Blumenthal at the Sunlight Foundation titled “Executive Branch Agencies and Web 2.0″. There, I was glad to read about the GSA (General Services Administration) advocating social media inside of government. The GSA has pleasantly surprised me more than once.

Surprisingly to some, the GSA does more than manage government buildings. Did you know that its Office of Citizen Services runs USA.gov? WhiteHouse.gov has new life thanks to the Obama administration. Perhaps we will see a similar shift in USA.gov as well?

How quickly and pervasively will government adopt social media? I’m not holding my breath; it won’t be fast and it won’t be easy. To zero in on just one element of the challenge, I don’t expect any executive agencies to move from “Web 1.0″ to “Web 2.0″ as a simple matter of a technological shift. An agency will have to understand and appreciate the importance of collaboration culturally, not just technologically.

I know first-hand that at least one group at GSA that embraces the ideas of collaboration both online and offline. I have attended several collaborative expeditions hosted by Susan Turnbull of the GSA. These bring together a diverse group of people from government and industry. These workshops break down traditional barriers in government. This spirit of in-person cross-pollination helps to motivate and stimulate online social media connections.

How can I improve change.gov?

I want to find a way to personally get involved to improve change.gov. Just jumping into the site itself doesn’t seem to cut it for me. Submitting through the contact form doesn’t feel satisfying either. I want to engage more fully.

I’m not star-struck by change.gov. Yes, the team is iterating quickly, doing good technical work, and rightfully impressing some people. Their progress is incredible by government standards. Let’s give them credit for that. But change.gov should also measure itself according to a broader perspective. The team behind change.gov should challenge itself by asking “What is possible in the field of online participation?”

The field of online participation is relatively young. I’m not sure that anyone who watches this space really knows what is possible. So I don’t think we know what the “bar” for achievement should be. Randy Pausch probably said it best: “You obviously don’t know where the bar should be, and you’re only going to do a disservice by putting it anywhere.”*

I’ve got questions about the big picture of change.gov, where it is going, how internal decisions get made, and what organizational capacity backs it up. You can see some in my prior blog post. Every question seems to lead to another.

Asking these questions comes naturally to me, but I also want to:
1. Find out the answers to my questions
2. Find out if change.gov is asking these questions of themselves
3. If not, find a way to bring up the questions to the change.gov team

How can I accomplish these goals? Here are some ways:

1. Write. Blog. Tweet. Argue. Persuade.

I’ve done some of this and could do lots more. I’ve got all kinds of energy and ideas pent up. You can get a small dose if you follow coinsight (my account for Collective Insight LLC) on twitter.

That said, writing is only the beginning. I don’t think I’m going to be satisfied unless I can convert these rants into action!

2. Put pressure on change.gov to improve.

Perhaps I could join forces with an organization that can help. This is a good idea in theory, but I’m not sure that I’m going to find an organization that is ready to ask the tough questions and apply the kind of pressure I’m talking about.

To the average bystander, change.gov is kicking butt: why criticize something that is working just fine?

On the other hand, those who are tuned into e-government, online participation, and wisdom of the crowds see the imperfections in change.gov. Despite this, I suspect that these mavens are quite pleased with the progress so far. They are hanging back and holding back their criticism. For now.

I must admit that I don’t just want to criticize for its own sake. I want to engage in a discussion for the sake of improvement. I want to criticize because it is the first step to rethink, restructure, and rebuild.

3. “Work around” the problems of change.gov.

It is possible that I could find ways to improve change.gov indirectly. For example, I could build a companion Web site — perhaps it could screen-scrape to get the underlying data from change.gov and package up that information in a more usable way. The Sunlight Foundation is an inspiration in this regard — checkout their post about Opening Your Seat at the Table.

I like this approach, but it has some limitations:
1. You have to work hard to get traffic and attention to the companion Web site
2. It is a second-best use of resources (it is inefficient)
3. The companion site may be brittle (a change to the original Web site can break the interconnections)

4. Join the change.gov team.

This would be awesome. It is easy to be an armchair quarterback, but there is nothing like being on the actual team. Sitting down and understanding the vision and constraints that the change.gov team faces would be eye-opening.

Now I just need to figure out how to make it happen! If you have suggestions, please let me know.

Perhaps my chances are unlikely. Still, I’m confident that my background and experience would be useful to the team. You can find my professional details, including my resume, over on my personal Web site.

Notes

* You can get the back-story about the Randy Pausch quote by watching watching his last lecture.

Questions about change.gov

I am an e-participation geek*, and I have a great hopes for what is possible in the future with change.gov.

I have lots of questions about the Web tools and the team behind it. Here are just a few:

  • What is the vision of change.gov? Where is it headed?
  • What are the metrics for success at change.gov?
  • Where does the change.gov team fit into the transition team’s power structure?
  • After the inauguration, what happens to change.gov?
  • Does the team have in-depth debates about what wisdom of the crowds really means?
  • Do team members think that designing civic participation is a key part of their job?
  • Do people in the group disagree as to what kind of ranking systems are best?
  • How many team members roll their eyes when they hear “Web 2.0″?
  • Has the team tried to quantify what it means for “the best ideas rise to the top?”
  • Are there people on the team that are passionate about civic participation?
  • What particular civic engagement technologies inspire the team?
  • What first-hand civic engagement experiences inspire the team?

What questions do you have?

* For example, I’ve attended and sponsored eDemocracy Camp 2008, presented at Online Deliberation 2005, and helped a teammate pitch a project at the “Constitutional Convention: Building Democracy 2.0″ conference.

Would you approve the Merb+Rails merger?

You probably have heard that Rails and Merb [will] Merge.

According to the Rails and Merb blogs, both teams agreed, and that’s that. But in other industries, things aren’t so simple. If Google and Yahoo wanted to merge, the antitrust authorities would want to get involved.

But in the open source community, we don’t have antitrust regulators. But what if we did? It might have been fun if the Ruby community had the ability to approve or deny the merger. In doing, the Ruby “oversight committee” might ask this question: is a merger or competition better for Ruby Web developers? What does “better” mean? The criteria that come to my mind are: performance, modularity, innovation, interoperability, source code readability, adoption (open source projects require a certain level of adoption to be sustainable), and efficiency (are the community resources being used effectively, or are they being split between projects that are very similar).

I’ve leave the full analysis as an exercise to the reader. :)

EPA: Carbon Dioxide Rulemaking

The EPA is accepting public comment about carbon dioxide. The deadline is Friday, November 28.

You may want to read the source document, EPA-HQ-OAR-2008-0318. It is titled, “Advanced Notice of Proposed Rulemaking for Greenhouse Gases Under the Clean Air Act”. To comment, submit your comments on regulations.gov.

You can also make your comments by submitting through an advocacy form. Here are some advocacy organizations supporting the CO2 regulations:

And here are some advocacy organizations opposing the CO2 regulations:

If you want to read over the docket documents in hard copy and live near DC, you can always head over to the Air and Radiation Docket and Information Center. ;)