Posts Tagged ‘Programming’

ajax mashups?

Friday, June 6th, 2008

Anyone out there (among my 2 1/3 readers) know anything about doing an asynch web mashup? I’m looking at starting with a page and a muckload of javascript (I guess) to pull and parse several pages and represent data.

I’m pretty sure it can all be done client-side, but I’ve never noodled around with javascript so I’m not sure what to start googling.

Is this driven by xsl transforms? Dom queries?

NO idea.

date.8601 XMLRPC::Lite perl MetaWeblog

Friday, April 18th, 2008

Good christ this stuff is a headache. Perl has this wonderful module that allows you to build simple xmlrpc clients and servers very easily.

It looks at the structure of your request and figures out by the data type how to map it in to xml by playing data type guessing games.

Unless you pass it a date, which it treats as a string.

Now, xmlrpc has an explicit date type. So if you’re using XMLRPC::Lite to call an api method (for instance metaweblog.newPost) and pass it a date in the request structure (say, in the ‘dateCreated’ or ‘date_created_gmt’ fields), what the server gets isn’t the date field, it’s a string field, even though the contents are the same.

How to force it to call the thing a date I have no idea.
Currently I’m looking at rewriting the damn client in python.

But my eyes keep sliding over to my old (but pretty damn robust) c++ xmlrpc libraries. I could use that to generate a request and, if I was feeling lazy, just pipe the thing into curl or wget.

Damn yous java!

Wednesday, April 16th, 2008

I code in java very rarely.  There are a couple good reasons for that and an awful lot of bad ones.

The unfortunate side effect of this is that There are about two dozen little things you’ve got to remember in order to get the java compiler to simply function that are tough to track down if you don’t remember what they are.

The one that’s been biting me in the ass for DAYS is that you really need to explicitly specify a jar file itself.  Even though the variable in question is classPATH.

Days.

I had this crawling sensation that there was something about this that I couldn’t quite peg, but that I’d been there before.

It took a few rounds of looking at command lines, directory contents and error outputs with an in-house java expert before she said… “wait… where’s the jar name?”
That moment opened the door to the flood of past lives where I’d gone through this exact same exercise, casting down java as being “just fucking stupid, written by retarded tripping monkeys.”

“SHIT!” I exclaimed rather unprofessionally over the phone.
“What’s wrong?”

“Nothing, you’re right.  That’s it.  I’ve been here a dozen times.”

“Well, I’m not guaranteeing that’s the problem.”

“You don’t have to.  I will.  That’s it.  Shitshitshitshitshitshit.  I should know better by now.”

So yeah.  Days.

- Retarded Tripping Monkey