Saturday, April 21, 2012

Weekend - tertainment

saw hunger games in the cinema this weekend
it was pretty good, and although i haven't read the book myself, it seems to follow the story well
the districts reminded me of the timezones from in time, segments distancing the rich from the poor
my only real complaint is that it felt unfinished, which is to be expected as the first in a trilogy

although i'm not a big star wars fan
i picked up a comic tag and bink and book darth plagueis from the library
looking forward to getting back into some reading

fringe is in high gear with lots of reveals and drama
with alter lincoln's death, broyles being revealed, and more insight into jones and his plans
i can feel the end of the season coming, and hope for atleast another partial season to follow

Tuesday, April 10, 2012

PAX East 2012

Here's a rough overview of my weekend in Boston:

Arrived late Friday missing keynote and Q&A (after walking from hotel)
played minefield in classic arcade
played the secret world in expo
saw the natural selection setup in expo (awesome since i remember playing it as a halflife mod back at lan parties)
lunch at flour bakery, grilled tofu sandwich (limited selection, usually only 2 vegan items)
played my last night on earth in tabletop (basic die z die scenario)

Had my thai vegan for dinner on Friday and Saturday (all vegan, but service was lacking)
Stayed at hyatt regency, close enough to walk to BCEC but thankfully got rides with shuttle/car since weather was chilly

Saw Penny arcade draw a strip and Q&A (barely made it after walking to get breakfast at flour bakery)
played more minefield and bosconian in classic arcade
played primal carnage in expo
played more last night on earth in tabletop (escape in trunk scenario)
caught second half of concerts with jonathan coulton (re your brains!) and mc frontalot (epic dubstep wubness yellow lasers version)
played zombie dice

And lots of wandering around checking out the other setups/games in expo, cosplay outfits, 8bit music, rockband stage, etc.

Had to head back early on Sunday so missed this day

Thursday, April 5, 2012

Lingering Defect

I like debugging code and solving defects.
And I like reading someone else's code and understanding it.

So these two come into conflict when the defect is in a black box system (from my view).
I interact with the web service, I have integration tests against it, I have ideas on how it should work.
And so when these are all raising red flags to me, I raise up the issue, since sadly I can do nothing about it.
All I can do is provide evidence of the bug as best I can.
Response comparisons between environments, screen shots of views using the service, etc.
And hope for another developer to investigate, and prove me right or wrong.

But it doesn't always work, and can lead to meeting after meeting, to just point fingers (ie "not me, must be you").
Am I mistaken? Is it my client code? What did I change? Can't I see it's working?
Which is all together frustrating.
Really what I want to do is just look though the code myself, but I cannot.

And I imagine a manager's perspective is not the best for discussing a specific defect.
With no personal knowledge of the code or of recent changes or a developer's secret "fix" that may break another part of the system,
a response like "nothing has changed" would be expected.
And I'm sure completely wrong. Code is always changing, or we would be out of a job.
(I know these are sweeping generalizations, this is purely ranting)

Saturday, March 31, 2012

TV Returns

So glad to see many returns to TV.

In Supernatural s07e17 the born-again identity, castiel is finally back!
Well kinda, or atleast briefly, which I was at first excited about and then not

For Fringe s04e15 a short story about love, more on the observers and peter/olivia
We get to see the return of the drill/egg from the beginning of the show (s01e04 beacon)
I actually enjoyed the nina and olivia connection, it was touching
And we get the answer to the universe/timeline debate, which is pretty much how I thought it would be resolved (somehow it would change back to our original characters)

And of course this means new Fringe podcasts as well!

And finally the long awaited return of Game of Thrones with s02e01 the north remembers
Didn't feel too thrilling but setting up the story with things to come and a brutal ending

Tuesday, March 20, 2012

Deploy Woes Continued, Bad Data

As I've mentioned earlier, issues happen with deployments.
And also post-deploy, both big and small.

Code assumptions
Assuming the data is in a good state. But there is always bad data.
Especially when using a bad UI framework, an old database model, and legacy code written under old assumptions.
And in trying to slowly cleanup a database for example, scripts can run fine testing in the Dev or QA environments. But if these aren't synced up with Production, it can and will fail there.
Suddenly a value is NULL unexpectedly, error error. Oops. Fail.

Code management
Ambiguity for who owns the code and who is responsible is killer.
And on that same note, who understands deployment steps.
Having a lone wolf coder on fundamental code doesn't help.
It's far to easy to be heads down on your own work and ignore it, until it bites you.
More code reviews, more shared knowledge.
So you don't deploy to production and find it isn't working because it's only half deployed. Opps. Fail again.

Saturday, March 10, 2012

Abe Hates Vampires

I stumbled upon a trailer for the Abraham Lincoln Vampire Hunter film coming out later this year. And this made me want to read the book first in preparation.
But I found an even better solution, the audiobook, which works well since I enjoy podcasts and I can listen during my commute and at night.

So far I've flown through it and really enjoyed it. I like the mix of fact and fiction, giving it a realistic spin (as a retelling of Abe's journals). I like the premise that slavery and the civil war were primarily because of vampires. I was hesitant of the reader during the intro (and Edgar Allen Poe tie in), but otherwise it was good.

John Carter (Virginia) of Jasoom

Went to see the John Carter film in the theater.
I enjoyed it more than expected, but then again I enjoy most scifi movies.
I liked the mix of different times/places or atleast civilizations with different technology, aliens of mars and civil war veteran. A little bit of the cowboys and aliens feel mixed with conan.
I enjoyed the mysterious bald men in robes influencing events, reminding me of fringe (bald,suits,fedora), adjustment bureau (suits,fedora), etc.
I didn't necessarily like all the CG and especially didn't like seeing it in 3D (gah hate it).

One thing that I enjoyed the most was the concept of traveling to/from Mars.
Specifically the notion of being copied and your body being in some sort of stasis.
How long can your body last in this state? How does it survive?
What happens to the copy when you return? Does it just disappear?
What about if your copy dies? Like what happened to the Thern who was shot on Earth, did he return to Mars?

The history of having a film created based on the books is interesting.
Seems that the film is different enough to not ruin the books, if I ever get around to reading them.

Sunday, March 4, 2012

Fringe break

Time for a Fringe break and I have finally caught up on the show and podcast.
The last episode before this break was huge, s04e14 end of all things.
Finally some explanations, about the observer september and nina, explaining what happened to peter, more about jones and olivia's powers.
There was so much packed in this episode, as it seems this season has been.
Feels like it is finally pulling things together (even after the whole universe vs timeline confusion), tying back to the first season even.
I really appreciate it, especially with the rumors of it being cancelled.
I'm sure it's bound to happen soon enough, same with Supernatural, and I can only hope good shows appear at some point to replace them. Those are definitely my top running scifi shows.
I can look forward to rewatching it all at some point too.
But for now I am hoping for a 5th season, even if shortened to give it a proper ending.

Wednesday, February 29, 2012

Spring JDBC

Took a very short break from JPA and tried working with Spring JDBCTemplate for a small project.
It's a mock version of a complex super optimized service using a lot of custom native sql.
I appreciated the simplicity of JDBCTemplate, and specifically the NamedParameter version.
I found the RowCallbackHandler useful for my case where each row didn't necessarily mean one object, and I was able to reuse the handler across different queries.

One problem I had was attempting to avoid creating new tables, and thus using what I had for columns. One problem was the indexes missing for the searchable columns in where clause.

But another more interesting one was needing to map two numeric columns into a unique numeric key. And the key is limited to a long value. In the end, I was able to combine the two numbers using 32 bit shifting to create the long value, treating them both as ints (AA+BB=AABB). With the issue that it would not work if they were beyond the max int value. Fine for now.
And this ended up working great, being able to encode the column values into a single unique key and translate them back into the separate column values for querying.

Tuesday, February 21, 2012

Admitting defeat and victory

tl;dr: bad data for testing can waste a lot of time.

I spent the last week or so trying to solve an issue.
The original goal was to reimplement an integration with a black-box system.
And it wasn't working.
Not only was it failing, but each testing request attempt crashed the system, preventing further testing without someone to restart it.
And of course there was no useful response or error info with the failure.

So I investigated and found an issue with the protocol and fixed it. No change.
As a baseline and comparison, I brought the old code into the new project. Same outcome. Failure without a cause, system down.
At this point it is getting too late into the development cycle and time to prepare the backup plan. This involved the new code calling the old project (not ideal since goal was to replace/remove it).

This is a difficult process: to admit defeat.
To admit that the world does not work as you expect it to, especially as a developer. To abandon your grand idea and accept your least ideal path. To hope one day to be able to come back and fix it given the time.
And in the end, the results were the same! Still failing.

Now this pointed to the request data being bad.
I had suspicions since it was one of the few differences (sending a remove command for something that didn't exist).
My guess was partially correct, but the root cause was bad test data. The ID being used was not valid in this dev environment. Normally this fails with a useful error message for other commands, but for remove it crashes the system.

So after a painful slow stretch of testing (having only 1 chance to test before killing it and waiting for restart), it wasn't even an issue with my code.
After using a valid ID, all implementations worked as expected.

Yes, this issue with bad test data had come up recently here.