jeff yen

14Dec/110

Hacked

Well, my site was hacked... over 3 weeks ago. I suppose it's a sign of how out of balance my life is right now, when my entire online presence can get taken over by some ridiculous hacked webpage, and I don't notice it for nearly a month.

At any rate, I'm restoring from old backups, ruthlessly wiping out whole swathes of directories on my server, and generally cleaning house. I suppose eventually I'll come back with a leaner, more secure web presence; until then this whole thing has just been a colossal annoyance.

25Oct/110

Cantaloupe

I beg to differ.

IMG_20111018_113038IMG_20111019_123547IMG_20111019_130248IMG_20111021_175449IMG_20111021_175600IMG_20111020_163117IMG_20111020_165455IMG_20111021_123019DSC_0075DSC_0022DSC_0088DSC_2695副本2cun

 

The actual ceremony is still going to be April ‘12, invitations will hopefully be going out in the next few weeks.

Filed under: Everything, Travel No Comments
14Oct/110

Flex and PHP Remoting: Typed Value Objects

After following a combination of Mihai Corlan's and Alan Gruskoff's excellent instructional posts on Zend AMF remoting with Flex, I was having some problems with returning typed objects from AMF into Flex.

The tear-your-hair-out-at-midnight-and-dream-about-running-away-and-opening-a-bar-in-Madagascar type of problems.

No matter what I did, AMF was returning generic Objects into Flex. I tried (what I thought was) everything. Octuple-checked my PHP value object classes, my PHP gateway, my PHP services, the metadata on my AS3 classes; nothing was working.

On a whim, manually imported the AS3 value object class into the test MXML component in which I was using the RemoteObject. No effect; still just getting arrays of Objects.

Finally, in desperation, I created an instance of the AS3 value object in the MXML component; I think at the time it was named "goToHellYouBastard," or something similar. It didn't do anything, wasn't getting sent any data, and served no function but to sit there and look enticing, like a judas goat for my AMF value objects.

Worked like a charm. Oodles of typed objects returning from AMF.

So, for Zend AMF to successfully map to a value object class in Flex, on top of the framework stuff you need to get them talking to each other, it appears that you require:

- IDENTICAL value object classes. If you have methods on your value objects, no go. You'll have to instantiate them as some other class, and recast or loop through the properties and transfer them over after they come into Flex. I'm still working on how to do this elegantly.

- A setClassMap for each mapping in your PHP gateway. Please note, it appears you don't need to add any path/package information for these classes; regardless of where your classes are, it appears that: $server->setClassMap("ValueObjectClass","ValueObjectClass"); will work fine.

- [Bindable] and [RemoteClass alias="ValueObjectClass"] metadata in your AS3 value object class.

- At least one instantiation of the AS3 value object class within the AS3 class from which you are doing the remoting calls.

For some reason I was under the impression that this wouldn't be necessary. I was going to just grab all my VOs in a service call and hork them off to a model somewhere for processing, but it seems like I need at least one instance to start with. At any rate, I wasn't able to find this specific information anywhere else (or at least, didn't notice it); hopefully this will be of help to someone.

Filed under: Flex No Comments
10Aug/110

Protected: Re: hi

This post is password protected. To view it please enter your password below:


Filed under: Everything No Comments
19Jul/110

Moderately offensive recipes #1: F*ckin’ carrots.

In an attempt to get myself writing again, but in a way that lets me ease into it without having to be creative at all, I'm going to post the occasional oddball recipe I come up with in an attempt to feed myself.

So.

Today's recipe is inspired by... I kind of want to say Thai food, but I'd be lying. In reality, it was inspired by what was in the fridge when I got hungry yesterday.

In order to truly understand some of the origins of this recipe, and possibly those of some to follow, let me explain my current situation.

Lately, I have been living as something of a nomad. I signed an agreement on an apartment that starts at the beginning of August, but in the meantime I am bouncing around town, depending on the charity of friends and family -- and family of friends.

This has led to an interesting confluence of requirements when it comes to my (and my hosts') kitchen(s):

  • The things I take from place to place can't spoil easily.
  • These things also need to be portable, because I am lazy and hate hauling heavy things around.
  • The things I buy I need to be able to eat for almost any meal, so I can use them up quickly, and also because I hate having to go back to the store because I'm missing one crappy thing that some meal depends on.
  • Everything should be fairly inexpensive, because... well, because I'm a cheapass.

So essentially, my pantry is comprised of two shopping bags; one full of my knife, spices, and various fats, and another one with an assortment of fruits and vegetables.

I can honestly say though, it's been a while since I've enjoyed cooking as much as this.

All right, so on to the first and possibly last recipe.

This was created... let me see... yesterday, when I realized that my latest trip to the store, combined with a bout of absent-mindedness, had resulted in a fridge stocked with two pounds of carrots, three limes, a lemon, and a one-pound bag of dried garbanzo beans.

Don't ask me why the garbanzo beans were in the fridge, I couldn't answer you even if I wanted to.

Dinner time rolled around, and of course the garbanzo beans had to soak overnight, so I couldn't use them.

I contemplated the carrots, willing them to become a carnitas burrito, or a steak.

There must be, I thought when this proved futile, some way I can inject spice and fat into this equation.

And so I came up with this. I have no idea if it's original at all, and it still needs some tweaking, and of course I am just guessing at the measurements, but I've had this for two dinners in a row now and I'm pretty sure it's delicious.

 

Ingredients*:

  • 1/2 lb of carrots (about 4 good-sized carrots), peeled and sliced into rounds or strips.
  • 1/2 a lime: Shave or grate the rind off -- that's right, finally here's an opportunity to use that MicroPlane you bought five years ago after watching Rachael Ray. Get rid of as much of the lime's pith as you can, then roughly chop the flesh and set aside.
  • 1/2 of a lime: That's right, another 1/2 of a lime. Math wizards will notice that this means you need around one lime. Don't do anything with this half, you'll just need a little bit of its juice.
  • Butter
  • Extra virgin olive oil (optional)
  • Fresh garlic, 1 large clove or equivalent, minced.
  • Fresh ginger (same amount as the garlic), minced.
  • 2-3 Bay leaves (optional)
  • Dried japones chilis (if you desire/can tolerate the heat), cut in half if you don't like bits of super-hot chilis in your carrots, otherwise torn/crushed/chopped. You could use dried red chilis of any kind really, but I've discovered japones have a great aroma to them that just kick chile arbols' ass all up and down the flavor street. I used about four large ones, because I am a MAN.
  • Salt (preferably kosher, I guess, but I can't really tell the difference)

* If you want a simpler version that's "cleaner" tasting, get rid of the ginger, bay leaves, lime rind, and chilis.

Prep time:

5 minutes, 7 if you include peeling the carrots.

 

Cook time:

10-15 minutes, depending on how crunchy you like your carrots.

 

  • Melt some... I dunno, maybe a tablespoon... of butter in a skillet, along with another tablespoon or two of olive oil, over medium heat. Vary the proportion of butter to olive oil as you like; I personally kind of prefer using all butter, but I feel guilty using that much butter, mostly because I've seen Paula Deen's show. The point is to have enough fat to fry the aromatics and coat the carrots, so do as your conscience and cardiovascular circumstances dictate.
  • Once the butter has fully melted, dump in the rind and chopped flesh of half a lime, bay leaves, ginger, dried chilis, and garlic.
  • Let them gently fry until the garlic is just starting to turn brown, then dump in the carrots and toss to coat.
  • Give it a healthy pinch of salt, turn the heat down to medium-low. Squeeze in a little bit of lime juice and toss from time to time. Continue cooking until the carrots reach the desired level of tenderness; I like them a little soft all the way through, but still with a little bit of bite. If I were a hipster foodie, I would probably airily call them al dente while casually adjusting my vintage black glasses frames with no lenses.
  • At this point, fish out whatever spices you don't want in the final dish (I just take out the bay leaves, but for most this will be the point where you remove the bay leaves, lime rind, and chilis).
  • Season if needed, and squeeze in a few more drops of lime juice.
  • Serve.

Serves 1 me for dinner, or three to four normal people as a side dish, which is how I'd serve it if it wasn't just me sitting around in my underwear eating the stuff.

The bay leaves and sour/bitterness of the lime rind hit first, tempered with the creaminess of the butter. Then the heat from the chilis and the slightly sweet caramelized lime flesh shows through, and finally you get the sweetness of the carrots, all of it with a thread of saltiness.

It's kind of a weird flavor combination, I'll grant you, but I've been finding it addicting.

Filed under: Everything, Food No Comments