Maritimes JUG – First Meeting Recap

On Wednesday, I gave a talk about RESTful based web services for the local Maritimes JUG. This was the first Halifax meeting and also my first public talk since my disastrous Ruby on Rails presentation a few years back. Thankfully, I had learned from my previous experience, and while I was doing a semi-live coding demo, I also had a completed copy of my demo to fall back on, in the event of typos.

My presentation was an introduction to  JAX-RS, the Java API for RESTful web services as well as an intro to JAXB, since the JAX-RS frameworks all seem to use it for XML serialization. The frameworks for JAX-RS use simple annotations to define the web services, and if you aren’t trying to do something complicated,  it is really easy to get going.

Overall, I think things went fairly well. I had a few stumbling blocks in my demo, but made my way through. There were about a dozen developers there, who seemed to get what I was saying, and there were a few good questions, all of which I was thankfully able to answer. After my presentation, I  had a few good talks with various people, including web development, hosting challenges, and some of the limitations of JAXB. Overall, for a ‘first’ meeting, I think it went pretty well. Thanks to Sheep Dog Inc for providing a venue.

For those interested, here are the slides and demo project.

Homemade: Honey Lemon Ginger Chicken

Had a few friends over today for dinner. I’ve been experimenting with marinades a lot lately. Unlike some of my recent experiments, this one actually turned out quite well.

Ingredients:

  • 4 chicken breasts
  • 2 teaspoons ground ginger
  • 1/2 teaspoon garlic salt
  • 1 tablespoon honey
  • 1/4 cup lemon juice
  • 1/4 cup olive oil
  • 1/8 cup soy sauce

Instructions:

Mix all the ingredients (except chicken) into a bowl. Marinade the chicken in the mixture for 3-5 hours. Bake for half an hour. And voila!

Homemade: Iced Tea

I’ve been making my own iced tea for over a year now. It happens to be easy, cheap, and awesome. A few friends have asked me about it from time to time, and I have given them the basics of my particular technique, so figured I should expand upon it a bit at some point.

I tend to make iced tea in 2 litre batches. For every 2 litres, I tend to use 8 tea bags worth of tea. Not all of these should be caffeinated. More than 5 bags of caffeinated tea tends to go from ‘good caffeine’ to ‘enough caffeine to cause your hands to shake’. Given that there are plenty of flavored decaffeinated teas around where I am, I tend to use 4 bags of caffeinated tea as a caffeine base (usually orange pekoe) and the other half as decaffeinated flavored tea as a flavoring base. If you don’t care about the caffeine, feel free to omit the orange pekoe base. It doesn’t really change the flavor.

Whichever tea bags you choose, let them steep for a few hours (I tend to do mine over night). When removing them, don’t squeeze the bags, as it tends to result in not so good flavoring in the iced tea. After steeping, I tend to add half a cup of sugar. From there, you can also add stuff like a tablespoon or two of lemon juice, lime juice, cut up fruit, or other additional flavoring. And that is it really. Simple, with plenty of varriation.

A few things I have experimented with and have NOT managed to do successfully:

  • use honey instead of sugar
  • Roobios tea for flavoring doesn’t seem to work out quite well for the ones I have tried.
  • Bluckcurrant tea as flavoring. One of the worst batches of iced tea I ever made.

My favorite recipes:

Orange Peach

  • 5 bags of mandarin orange flavored tea
  • 3 bags of ginger peach flavored tea
  • 1 Tablespoon lemon juice
  • 1/2 cup of sugar

Apple Pear

  • 5 bags of apple pear flavored tea
  • 1/2 cup of sugar
  • (Optional) Some apple slices

Lightly Lemon

  • 4 bags of orange pekoe tea (as a caffeine base)
  • 4 bags of lemon flavored tea
  • 1/2 cup of sugar

Easy and delicious!

Upgrading my RAID array

Last weekend I bumped up the storage capacity of my workstation. Given that I had to look up several sources to upgrade (my setup isn’t exactly straightforward) and the fact that one of those sources is now inexplicably unavailable, I figured I should leave myself instructions somewhere for the future.

With the exception of hooking up the new drive, this upgrade didn’t require powering off at all. Such are the joys of a RAID5 array.

My setup is an encrypted software raid5 array on linux, which sits at /dev/md0

  1. Put in the drive and power on.
  2. Figure out what the name of the drive is (mine was /dev/sdd)
  3. Add the new dri9ve to the array as a hot spare via “mdadm –add /dev/md0 /dev/sdd”
  4. My raid array has a write intent bitmap, which prevents the array from expanding. I temporarily removed it with “mdadm –grow /dev/md0 -b none”
  5. Then I told the array to actually use the new drive. Since I was adding my 5th drive, the command was “mdadm –grow -n 5 /dev/md0″
  6. Waited for 24 hours for data to be migrated. Checked on the progress by using “watch ‘cat /proc/mdstat’
  7. Re-added that bitmap using “mdadm –grow /dev/md0 -b internal”
  8. Told LUKS to resize itself to use the new drive as well using “cryptsetup resize cr_md0″
  9. Once that was done, I had to resize the partition using “resize2fs /dev/mapper/cr_md0″

And done. The array started getting usable freespace immediately, though again it took a few hours to have access to all my new space.

Haven’t had any problems with this setup. However, given a friend’s recent drive failure, I hope to be very thankful of this setup when I finally do have problems.

Guest Blogging: East Coast By Choice

Recently, my twitter friend Kimberly, writer of EastCoastByChoice, contributor to Undeathmatch, and all around interesting person was soliciting guest posts for EastCoastByChoice. Given that people often ask me about why I came out east, I figured it would be a good tale to write and submit (it helped that I already had a draft of said story). Kim has graciously decided to publish my story. You can read it here.

Guest Blogging: Undeathmatch

Undeathmatch, a blog made up of some Canadian writers, has been pitting various supernatural beasts against each other in both literary and popularity wise over the last few months. This month, they had a call for guest posts, hoping for something that might go toe to toe with the winner of the last two rounds, werewolves.

So I wrote something. I doubt they could take on werewolves popularity wise, but I would like to introduce the latest contender in (un)deathmatch, the mighty Golem.

Let the match begin!

My Cyborg Life: Ear Upgrades

Late last year, I was reading the article “My Bionic Quest for Bolero“, which is an article in wired about a cochlear implant user who was trying to recapture the sound of an opera he loved before losing his hearing. During the article, he mentions being able to try out new software for his cochlear implant, and how eventually the software progressed to the point where the opera closely matched his last clear listening. A happy ending, to be sure.

Given that article was in 2005, I thought to myself, “Hey! I wonder if there are any software upgrade for MY cochlear implant.” 5 minutes of googling gave me an answer. Not only was there no upgrades for my implant, but my processor was going to reach end of life in early 2010. By the end of March, no more parts for it were to be manufactured.

So I contacted my audiologist for options and did some research. It turns out that there was a new processor model announced in September 2009, the Nucleus 5. Going over the product specs, I was getting a bit excited, and then I learned that it isn’t compatible with my current implant coils. Sad, but the other model, the Freedom, was also somewhat exciting. Everything behind the ear, more sensitivity, new software, all for the price of ~$8000 US. Gah.

The following day, my audiologist got back to me and told me that if I was still under the Ontario Health Plan, they would cover 75% of the cost, as Ontario has a program for medical aids like this. Sadly, I haven’t been covered by Ontario Health Care for quite a few years. My audiologist did suggest I contact the local cochlear team for options, as there may have been a similar program in Nova Scotia that she was unaware of.

Turns out there isn’t. However, the person I talked to was able to tell me that they had applied for funding to upgrade everyone they knew about. Unfortunately, I never informed them that I was in the province, so I wasn’t included and the money was all gone. She did offer to to apply for more money to cover my upgrade and to see what happened. Which obviously I agreed with, as the worst case is that they would say no.

So, I started to stress out a bit about this. $8000 US is a lot of money, obviously, and I wanted to have options if that had to come out of my own pocket. Upgrading wouldn’t be covered by my medical insurance (it would have been if I lost my hearing for the first time though). Upgrading wouldn’t be automatically covered by he NS government. However, if I was an Ontario resident again……. I will admit I considered moving back to Ontario and working for a year to get covered by the Ontario Health Plan again. Another option was to try to get a higher paying job anywhere else in the world, and pay it out of pocket. The final option was to wait until it broke, and pay then, and also hope that the latest version was backwards compatible by then (an extra $2000, but I figured it would be worth it for the latest version, which would also be supported longer).

Thankfully, none of those options needed to exercised. A few days before Christmas, the NS hearing organization called my up and told me that funding had come through, all I needed to do was pick out the colors of my implant and they would order it. A happy ending, to be sure.

3 weeks ago it actually came in, and last Monday I went in for an appointment to pick it up. Things are…. different now. It is certainly more advanced. After a week of it, I know the following.

Pros:

  • It all fits behind the ear. No more cords getting caught, pulled by animals and small children. No more cord being just a little too short when wearing formal wear. No more cord brushing my neck during horror films and freaking me out a bit.
  • It all fits behind the ear, so I don’t have to reach into my pocket, fiddle with controls, and receive odd looks. Now I can look like I am adjusting my hair.
  • Three microphones for greater coverage and sensitivity.
  • New software to take into account the new microphones and sensitivity. Noise reduction mode on this thing is MUCH better than my old model.
  • 4 hearing modes instead of just one. Currently loaded with 2 normal programs, two sound reduction programs. Going to see if I can get it loaded with: 1) Normal mode, 2) Sound reduction mode, 3) Robot mode, and 4) Chipmunk mode. Robot mode and chipmunk mode were maps that I had at various stages when I was originally getting the implant programmed, so I know they are possible.

Cons:

  • Battery life is shorter. Much shorter. 5-6 hour lifespan instead of the 24 hours my old model can get. I don’t know about you, but I am awake for more than 12 hours at a time. Batteries can charge in 4 hours, but this means I need to stop home and charge a battery if I want to use it all day.
  • There is some electronic warble when some people talk. A sort of metallicness to the end of their sentences. Others sound somewhat cartoony. Try having a conversation with your boss after he inhales a small amount of nitrous and see if you can stop yourself from laughing.
  • It’s all behind the ear, and this makes the ear piece bigger. Ear piece + glasses = sore ear. Ear calluses forthcoming.
  • The coil is larger, and heavier, and thus falls off easier. Been trying to adjust the magnet for optimal strength, but nothing fantastic so far. This really sucks for sports, as the old coil and sometimes the headset went flying. No more cord to rein in in. About time for a headband revival anyway…
  • Everything is proprietary. Batteries are proprietary so I can’t just go out and buy AAs when one dies. Technically there is a holder for watch batteries, but they are ‘high powered’ watch batteries which I also thing I just can’t go and grab easily. The audio connector jack is also proprietary, in that iPod cable cable. No longer will a standard 3.5mm audio cable do the trick. Pretty annoying, especially since this results in jacked up prices on items ($200 for a new rechargeable battery, $130 dollars for the audio cable).

I am hopping the first two cons will be eliminated if I went in for a reprogramming of the map. I am still technically using the one from my old processor, and while it does work most of the time, I don’t think it is optimal for the new microphones and sensitivity. Going to give it another week, and then we’ll see.

Idea: Grocery Inventory

So, while down in San Francisco, I picked up a touchatag rfid reader at Java One (had a really nice conversation with the developer to boot). Unfortunately, I haven’t gotten it working as of yet (Linux support is….. yeah and that is what I am running at home these days). But, I did have a really neat idea at the time involving rfid and inventory.

Basically, if you could tag your groceries with RFID tags and turn your cupboards into an RFID reader, you could have a running inventory of what if in your cupboards. Tie that into a web app, and you could access this inventory from say… your iPhone while at the grocery store. No more accidentally buying yet ANOTHER 1L tub of peanut butter when you already have one at home. Something similar to this has already been done here, which reminded me of my original idea.

Of course, currently tagging your foodstuffs with RFID now would be somewhat expensive, but the system can still technically be done using barcodes. As any Mac users might know, the web cam can be used as a barcode reader. Obviously, other web cams can become bar code readers as well. You could take a cheap netbook , mount it under your cupboards (assuming foodstuffs are kept in overhanging cupboards) and use it to scan in/out everything in your cupboard. Same effect achieved. Bonus in that you could use the laptop for other things in the kitchen, such as displaying recipes, listening to music, etc.

Thoughts?

Idea: The Notebook Superdock

Right before I left on vacation, a few employees at work were about to get upgrades of new laptops, with laptop docks.

During my vacation, I saw this article about a laptop where the screen can be popped out to operate as a low power tablet.

So…. I thought to myself, why can’t we do things the other way? I am sure there are plenty of people that have both workstations and laptops, so why don’t we create a dock that not only provides instant connection to ports, but also provides access to more CPU, RAM, Hard disk space, etc?

Some advantages:

  • Lower maintenance issues, as the user doesn’t have to ensure that multiple systems are up to date.
  • No need to configure multiple systems, as you are literally taking the same system with you everywhere, just having it work better when you are in a non-mobile workspace
  • Provides the convenience of a laptop, with the power and upgradability of a desktop.
  • You could have it so that your laptop’s files are synched to the dock’s storage when you dock your laptop, making for easy backups.
  • Building on the above – reinstalling/dual booting wouldn’t be as big a deal if the bulk of data is stored/replicated to the docks, as restoring data would be trivial.
  • The above two operations should be faster than USB/NAS solutions.
  • Given the assumption that files are replicated to the dock, in the event that the laptop is lost/stolen/accidentally left at work, you could conceivably boot your system anyway (without the latest files of course) given that you could have a keyboard, mouse and monitor attached to the dock, and the dock basically would be a computer system.

I could see this being valuable for a number of people: namely anyone who has to give demos and meet with clients, but still needs a beefy computer for the non-demo portion of their job. Off the top of my head, this could include animators/graphic artists, and software developers.

To those who know there history, something similar was done with the Powerbook Duo Dock, which added more cache and RAM, but obviously did not take off. Maybe now that people are focusing on small, lightweight laptops, the idea might be worth a second look?

Thoughts?

Just Walking Along…

Wow, hard to believe I haven’t written anything here for over a year now. Not that there hasn’t been anything to write about, what with that trip to Ireland and Scotland I took shortly after my last post, but… for the last year I just haven’t felt inspired to really write about anything (two server migrations, one which resulted in losing some data might have contributed to this). Obviously, as I am writing here, that has changed.

I’ve recently returned from a fantastic trip to the states. First was a short trip to Chicago/Indiana to visit my cousin Amelia, who is still not allowed to leave the US if she wants to get her Green Card. A good visit to be sure, we generally hang-outetry, a trip to Notre Dame (where I was inspired to write a narrative tale of Touchdown Jesus and also created the theory that the university was contructed by giants), a trip to the biggest (but I was assured still quite small) flea market I have ever been to (where I scored a signed copy of Cory Doctrow’s “Little Brother” for $2), and a trip to the awesome cheese factory (over 20 varieties of delicious cheese, with free samples!). Oh right, I also walked Chicago’s “Miracle Mile” and managed to go all the way to the top of the John Hancock Center, to take multiple photos of the tiny skyscrappers below.

Second was the main part of the trip: a visit to my friend Mark in the San Francisco Bay Area. Some highlights:

  • Going to the area that Starfleet Command will eventually be (fun fact, in that area is a Khan Playground, and a Halleck Street)
  • A 5.5 hour trip to the Exploratorium with Casey (we got to see them disect a cow eye and learned that Casey is easily amused with sand)
  • An equally long trip to the California Academy of Sciences (they had penguins! And chameleons!)
  • A cruise under the Golden Gate Bridge and around Alcatraz
  • Maker Faire, half the reason for the trip, which was everything I thought it would be and more (and contained far to many things to detail here). Funnily enough, at one point, there were 5 Dalhousie graduates all at the Faire at the same time (of course, I was the only one who doesn’t currently reside in California.
  • attended the JavaOne Conference (also too much to put down right here)
  • and of course, much awesome hanging out with Mark and co

The weather was fantastic, like a good day in Halifax every day, and given that I was struck down with a cold immediately after returning to Halifax, obviously I wished I had stayed in California.

Just as important as the awesomeness of the trip, I have started having some cool ideas again and even been inspired to start writing about them. Let’s see where this goes.

Next Page »