Skip to main content

Indexes on collections that don't exist: one of the mysteries of Mongo

I've been working on a Drupal module which aggregates and reports on some data from Mongo. In order to keep from having to re-do all the aggregations, the aggregated data itself is written off to a Mongo collection which is then retrieved and displayed when the reports are requested. To make the retrieval more efficient, I need an index on the table storing the aggregated data.

Mongo MapReduce FTW!

One of the systems I've lately inherited makes heavy use of Mongo for data storage, a data system I've not used previously. So, when the boss called tonight and said that his boss needed counts of an object in our system by state in the next 10 minutes my thinking went something like...

No problem, that's a simple SQL group-by....Oh, wait. This is mongo. Oh, crap! How do I do that?! It's a function; Map...Something.

A Mnemonic for the DC Metro Red Line

Now that I'm commuting into the city each day, I've been forced to actually learn my way around metro. It didn't take me long to get tired of checking my phone for the station map, so I put together a little mnemonic to help me remember the order of the stations on my route: Bethesda to Union Station.

Joining the Cult

AdorationOfTheApple
I've joined the Cult of Mac.

Architecting for Communities: notes on "Drupal Voices 175: Clay Shirky on Social Media Theory and Drupal"

Drupal Voices 175: Clay Shirky on Social Media Theory and Drupal
In his interview for Lullabot's Drupal Voices series, social media guru Clay Shirky made two points I found especially interesting, both of which have direct impact on how we design social sites.

Great introductory Agile videos

I came across these great videos giving a simple introduction to what Agile is and how it differs from waterfall. Unfortunately, it doesn't appear their author is making any more in the series.
User Stories from Agile Advocate on Vimeo.
Agile Planning from Agile Advocate on Vimeo.

DrupalCon Chicago wrap-up

DrupalCon Chicago is done. Now it's time to unpack, review and condense my notes, and begin to sort out how to integrate everything I learned into my processes going forward. In subsequent posts, I'll expand on each of the points below, but my goal at the moment is to lay out the biggest things I'm bringing back from the con.

DrupalCon 2012 in Denver

drupalcon_denver_logo

At the end of DrupalCon Chicago, the team working on the 2012 North American DrupalCon announced the location: Denver. What could be better than geekery and spring skiing?

What is Drupal?

In preparation for his upcoming keynote at DrupalCon Chicago, Dries has posted a request on his blog that Drupal users answer the question of what Drupal is to them. My answer to the question is:

Drupal is the lackey that I force to write the boring, repetitive code (e.g., log in/log out, change password, database CRUD operations) so that I can focus on the interesting problems.

DrupalCon Chicago

I'm attending DrupalCon Chicago, March 7-10, 2011
There's just over a month left until DrupalCon Chicago. I've been going over the final session list and I'm jazzed. Looks like some great sessions this year. Now I just need to figure out human cloning so I can attend all the sessions I want.

Redoing DataSmith's Theme

For the past couple years, I've been using the contributed Recycled theme. I really love the theme, but it's time for a change. Though, frankly, I doubt I would have gotten there if Recycled had been available in a Drupal 7 version.

A Tabbed Overview Page Using Tabs, CCK Fieldgroups, and Viewfield

I've been working on a travel site for a friend, highlighting Costa Rica as a tourist destination. To express the things there are to see and do in Costa Rica, I've created four content types:

  • Regions
    - areas of the country
  • Destinations
    - places to go within Regions
  • Tours
    - things you can do at a Destination
  • Hotels
    - places to stay

Hotels and Destinations are linked to Regions by means of a Node Reference field and Tours link to Destinations in the same manner.

A Tabbed Overview Page Using Tabs, CCK Fieldgroups, and Viewfield

I've been working on a travel site for a friend, highlighting Costa Rica as a tourist destination. To express the things there are to see and do in Costa Rica, I've created four content types:

  • Regions
    - areas of the country
  • Destinations
    - places to go within Regions
  • Tours
    - things you can do at a Destination
  • Hotels
    - places to stay

Hotels and Destinations are linked to Regions by means of a Node Reference field and Tours link to Destinations in the same manner.

Take Your Child to Work Day

Evan went to work with Molly today for "Take Your Child to Work Day." He was really excited to go and wanted to wear his suit. His first attempt at putting it on didn't come out so well, though. Looks like he's just coming home from a really great bachelor party.

The first 5k time-test: this is going to be more difficult than I anticipated

Posted in

I officially started training today for the Warrior Dash. I wanted to start by getting a baseline of how long it takes me now to run a straight 5k. So, with the help of Google Earth and an online application I found which measures GE paths, I mapped out a 5k loop through town.

The outcome: at what I would estimate as 80% effort (I didn't want to go all out on this run and have a stroke when I got home) it took me 33:59 to finish the 5k loop.

Installing Drupal 7

I've started working on getting the development version of Drupal 7 installed and running so I can get familiar with the changes that are coming and work on having a d7 version of my Post Reminder module ready when d7 hits production release.
No sooner had I installed the new version than I got my first error
Fatal error: Class 'PDO' not found in .../includes/database/database.inc on line 137

Testing Ubuntu 9.10 Netbook Remix on the Asus eee 901

I've been using Ubuntu on my desktop machine for some time now, so I'm intrigued by the idea of running it on my Asus eee netbook also. With the release of Ubuntu 9.10 Netbook Remix (UNR), I decided it was time to really check things out, especially since it can run from a USB drive without having to install the OS.

Post-Reminder 1.0 released for Drupal 6

I completed version 1.0 of the Post-Reminder module last night. This version clears up the three major issues I had with the 0.7 version released previously. Users can now see a list of all their reminders from their account page, the Amount of Time field is validated as an integer on reminder creation/editing, and an error is displayed on the reminder creation form if the site administrator has not set any content types as permitting reminders.

Post-Reminder module nearing 1.0

The Post-Reminder module is nearing 1.0 release. The major issues I felt the module needed before it would be worth of a 1.0 moniker were a user list of their own reminders, validation that the Amount of Time field was an integer, and an error message on the node creation form if no content types had been set as allowing reminders to be set for them. Those items have been accomplished.

School's out for me, in for Evan. Seemed like a good reason to celebrate

Yesterday was the official end of my last class at Capella. Assuming I don't fail my final paper, and there's no rational reason to expect I would, I'll have my degree in hand in a few weeks.

A few months ago, Molly found out that Walking With Dinosaurs would be in town this week and bought Evan and I tickets as a way to celebrate the end of my school, his beginning Kindergarten, and the impending birth of the twins.

Evan's First Day of Kindergarten

Ready to Go...Ready to Go...Today is Evan's first day of Kindergarten. The school rules are that you drive through the turn around area, drop the kid off and pull away. Evan was completely fine with that, but I had a hard time not getting out for my last hug-kiss-bonk before sending him off to school. I can't believe that tiny little boy we brought home from the hospital is big enough to go to school now.

When we picked him up afterward, he said he had a great time at school...and we got a note from his teacher saying he had a great day.Note from the teacherNote from the teacher