A couple of months ago, my wife learned that D Magazine a magazine promoting
the City of Dallas was having contest to determine the cutest pet.
The rules were simple enough: voting was open to the public, and the public was
encouraged to vote as often as it wanted for the pets in the contest. That is, there
was no limitation on voting, and voting was as easy as clicking a button.
So I wondered, given these rules, if I could develop software that would do the
voting for us: something I could run that would visit the link that was the
destination of the button click, but do it in a way that wouldn't create problems
for other users no denial of service or anything like that. Something that could
run inside of a loop and just click, but would also look like a browser to the server,
so the server would have data available to collect.
Over time, the project grew more and more mature. It really wasn't about my dog
at all it was about learning something new, and adding more features as I learned
more about developing in Windows Forms: I wanted this to be a desktop application,
something outside of my comfort zone. And honestly, I hadn't built anything in
Windows Forms since maybe just after high school.
As the project matured, I thought a lot about the pace at which the application
operated. I decided to introduce a slow mode to really pump the brakes and run at
a pace of one click per minute over several hours. Steady clicks at a rate that
should not interfere with any other traffic. Slow and steady would win the race
for us slow enough, in fact, that I even "wired in" sounds so I could run the
software minimized and hear a short beep each time a click was performed.
I also had the software output to a text file as an option, so one could see
the incoming status messages from the server. Shorter runs produced shorter logs.
One big breakthrough was in learning how to create menus. It made the app look
so much nicer than the simple tabbed interface I'd originally used.
I found that 8-hour runs of 500 clicks at 1 per minute was the sweet spot.
I probably went a little over the top near the end of development, when I added
web services. Two calls: one to report the parameters at instantiation, and another
made intermittently to update the current click count. Using the web services, I
could monitor the run without having to visit my computer; I could do it right from
a browser on my mobile device. The first here: implementing web services on a
desktop app.
This was never about the contest. My dog isn't really very cute. I don't care
about having a professional photoshoot. He's a little pizza-stealing asshole who
glues himself to me whenever it rains. He's not pretty. But we do love him, and
he loves us so much. No, our good boi is simply a beneficiary of the development
development simply done to satisfy my curiosity.
(Even if it was about the contest, there was nothing stopping the other 999
participants from building their own click machines too.)
The contest has two parts: the popular vote and the judging. How are we doing?
well...
He made it into the top 20!
D Magazine notified us today that pup is a finalist, and their art department
made us the faux magazine cover. For me, this is enough. Really. If there
were no judges involved, and the prize was awarded solely on the popular vote, I
would explain things and insist the prize go to the next popular pet. I wouldn't
feel right about that. But because there are judges, that tells me there's more
afoot here than just clicks.
(Besides, I feel pretty comfortable that he's not
the cutest in Dallas. I mean, look at him.)