Archive for July, 2007

Letter to the editor published in the Roundel

Monday, July 23rd, 2007

I recently wrote a letter to the editor of the Roundel Magazine, published by the BMW Car Club Of America, about my friend JP Cadoux at A1 Imports Autoworks in an effort to get the word out about what he does. I am kinda surprised they actually published considering I wrote in a serious manner but frustrated after reading silly articles about carbon fiber, xenon headlights, and other useless do-dads. Nevertheless, here it is.


article-about-jp-in-the-rou.gif

Patio brick work is finished

Tuesday, July 17th, 2007

After many many car trips to random houses in the bay collecting 100 year old chimney brick and a days worth of laying we are finally done. We chose a herringbone pattern which was a little more complicated but totally worth it. The whole project was pretty easy just time consuming. A little research, making sure your patio is square, and grading the dirt before the sand is all you need to do. More pictures and a video will follow once the lighting and beds are done.


brick-work-complete.jpg

Rebuilding the backyard

Monday, July 16th, 2007

My roommates and I just moved into a beautiful house that has been completely redone except for the yard. Two months later, 750 free bricks on Craiglist, many trips to the hardware store, and a sod delivery we are almost complete. Here is what it looked like before we moved in.

Dynamic Proxies in Java

Friday, July 13th, 2007

Up until recently I never had to write any code that dealt with reflection. Before now I worked for CNET which is basically a series of differnent CMS’ with one request, one response. My first week at the new job required me to build a JMS system that would accept method invocations across the wire seamlessly for the producer. Java.lang.reflect was the answer.


Once you can wrap your head around the idea its pretty simple to write. Essentially what we are attempting to do is shield the caller from having to know anything about the other method that is going to invoked behind the scenes.


public Class MyConcreteProxyClass implements InvocationHandler {

   Object obj;
   public MyDynamicProxyClass(Object obj)
     { this.obj = obj; }

  public Object invoke(Object proxy, Method m, Object[] args)
         throws Throwable {
     try {
        // do stuff
     } catch (Exception e) {
        throw e;
     }
        // return something
     }
}

Now we have to create the proxy interface which the caller will implement. Any of the methods of this class that he implements and fire will invoke method on the MyConcreteProxyClass object.


public interface ProxyInterface{
    public Object myMethod();
}


Now its time to create wire everything up. There are several ways to do this which help hide this proxying like a static factory method but this simply demonstrates how this works.


ProxyInterface proxy = (ProxyInterface)
Proxy.newProxyInstance(obj.getClass().getClassLoader(),
         Class[] { ProxyInterface.class },
          new MyConcreteProxyClass(obj));

More press for A1 Imports

Tuesday, July 10th, 2007

In an effort to the use social media to gain more publicity for the fantastic work that JP does we created this video and posted it on YouTube. Within the first day it recieved a few thousand views and was honored for two weeks on the site. It generated a lot of buzz on the Internet and was picked up by Jalopnik.com due to an anonymous tipster (myself). Here is a link to the post.

Coilovers installed on the 2002

Monday, July 2nd, 2007

I’ve owned this car for almost 2 years this August and for the life of me I have not been able to get this car to sit flat, i.e. not sag in the rear. I have replaced every bushing, removed every spacer, replaced the springs and shocks and still, the sagging continued. So I finally bit the bullet and replaced my front suspension struts with coilovers which allow for an adjustable ride height. Not only does the car sit level it handles better, especially squatting into a corner.


BMW 2002 with coilovers installed