My wife is still in Australia – it’s already Jan 1 there, but we’ve still got another 15ish hours to go before 2009.
Not sure if I’ll go ‘do’ anything this year or not. Generally we (wife and I) don’t do much on NYE anyway, so doing anything without her might feel ‘wrong’ somehow.
I might go grab some Bailey’s Irish something-or-other and have a few drinks tonight. Had some at my grandparents’ house and forgot how much I’d liked it! :p
Working on many small projects trying to get things tied up, and planning for GroovyMag Jan (tomorrow, hopefully), Codemash presentation (still working!) and PHP training (next monday!) Lots to do in the next few days!
I'm currently working on a book for web freelancers, covering everything you need to know to get started or just get better. Want to stay updated? Sign up for my mailing list to get updates when the book is ready to be released!
Christmas alone (mostly)
This Christmas is a little strange. My wife left me… to visit family in Australia, so I’m on my own. I don’t have any family around, so my prospects were going to be pretty solitary. I ended up making the decision to drive down to Florida to visit with my grandparents for a couple days. It’ll make a nice change of pace, but a heck of a drive (9+ hours). The majority of the day will be spent in the car, probably making some phone calls to family that’s spread around (michigan, kentucky, new york, california, new mexico). That might eat up a couple hours of the drive at least
I’m just getting a bit reflective here. This is the first holiday season I’ve been sort of ‘naturally’ on my own for many years. I’m having to make a big effort to go visit family this year. Not complaining, just realizing that it’s like this for some people all the time, and I’m a bit more grateful for how my ‘regular’ life is these days (outside of this holiday season!)
I'm currently working on a book for web freelancers, covering everything you need to know to get started or just get better. Want to stay updated? Sign up for my mailing list to get updates when the book is ready to be released!
Couple of thoughts on music piracy
Was reading a couple of blog posts on music piracy recently, and the same tired old threads kept coming up. “Music tracks are just advertisements for the artist – they should make their money selling T-shirts and tickets to live shows.”
I’ve contributed this rebuttal, as have others – “what about music that can’t be performed live, or wasn’t intended to be? Beatles’ Sgt Pepper being a prime example, but even most of Revolver couldn’t have been done justice ‘live’”. Rebuttals to that rebuttal inevitably come back with “technology is so great now – anyone can do it. Phish redid the White Album live, etc”. Not trying to be Beatle-centric here, just some points of reference that make most sense to me. Substitute Zappa or Pink Floyd or whatever to suit your taste.
The “sell tshirts and tickets” has always bothered me, but not until today could I put my finger on why. There are two separate reasons, really.
Point one: I don’t need that many tshirts. Really – I like dozens of bands and hundreds of albums – I do NOT need more clothes or trinkets to memorialize them. This adds to clutter/waste, enriches the Chinese companies that manufacture this stuff, and is wasteful (did I mention it’s wasteful?)
Point two: You can *not* replicate the range of experiences people can have with music at a live concert. I don’t enjoy much live music because there’s so much *other* stuff going on around, and usually I can’t afford front row seats for larger shows (Stones, etc.) And for smaller shows, well – I’ve been to a few, and they were enjoyable, but were poor substitutes for the sonic brilliance and subtle textures I get listening to the artist’s CD. Live concerts are just *one* experience – a very short lived one for most people – that you can have with an artist’s music. There’ve been plenty of times I’ve cried at music tracks while riding in the car, or sitting at home being reflective of life, while listening to music from artists that were able to articulate my exact feelings for that moment. I find myself reconnecting with old music on long trips that bring a new perspective to how I used to see certain issues, or help me to reframe my thoughts on old friendships.
In short, the music on an artist’s album can often become the soundtrack for many chapters of your life, for years to come. Marginalizing that power by implying that artist’s music should be given away simply as a marketing tool to attract people to live shows (expecting them to buy shirts to ‘support’ the artist) is narrow-minded, short-sighted, and dare I say insulting to the many bands and artists that strive to achieve something more permanent.
I'm currently working on a book for web freelancers, covering everything you need to know to get started or just get better. Want to stay updated? Sign up for my mailing list to get updates when the book is ready to be released!
Me griping about PHP :) (closures this time)
Yeah, that’s about all this post will be. I read an article from IBM developerworks on the upcoming 5.3 features, and something got my dander up: closures.
I first got acquainted with closures in Groovy last year, and love them. They make sense. The syntax is pretty easy, and feels natural in the language. Not so in PHP. Once again, inconsistencies are not just legacy issues in PHP – they are created anew for us to deal with for years to come.
Look at the example here:
class Dog
{
private $_name;
protected $_color;
public function __construct($name, $color)
{
$this->_name = $name;
$this->_color = $color;
}
public function greet($greeting)
{
return function() use ($greeting) {
echo "$greeting, I am a {$this->_color} dog named
{$this->_name}.";
};
}
}
Given that ‘anonymous function’ inside the greet() method is a closure, WHY NOT NAME IT THAT? The PHP Reflection API was updated to include a “getClosures()” method, but what would you get? They keyword “closure” doesn’t exist, but could have. Instead we now have the keyword “function” looking like two different entities – it looks like a function call when used with the () directly after it, and also has its traditional function fname() syntax still available.
I have to teach this stuff, and being explicit with a closure keyword would have saved a lot of headaches to come in explaining this stuff to people. Additionally, it would have been less to type.
Compare
return function() use ($greeting) {
echo "$greeting, I am a {$this->_color} dog named {$this->_name}.";
};
with
return closure($greeting) {
echo "$greeting, I am a {$this->_color} dog named {$this->_name}.";
};
What’s more explicit, easier to understand, and fewer characters to type? Given the recent namespace separator debacle (using \ as a namespace separator, and justifying it because it’s “fewer characters to type”), I can’t really understand the rationale behind the closure syntax.
To be fair, the closure syntax RFC was up at http://wiki.php.net/rfc/closures and I didn’t comment in time. So, I guess it’s all my fault.
Beauty and elegance have never been PHP’s strong suit, but it seems people went out of their way to make this unintuitive and bulkier than it needed to be. :/
On a more broad note, I really think the bulk of these changes (closures, namespaces, etc.) should have been put in php6 only, not in the 5.3 series. I understand the need for testing and such, but we’re implementing new functionality and defining how it is expected to work based on the current PHP5 Zend Engine. Whatever useful changes that might make a PHP6 faster/better/whatever can’t easily be implemented because the ‘new’ features are all dependent on a core engine that’s already 5 years old, which it itself was built with an eye towards backwards compatibility to PHP3. Strategically, it just feels like the wrong move. But hey, what do I know, right? I can’t write C code patches, so my views don’t really have much weight, do they?
I'm currently working on a book for web freelancers, covering everything you need to know to get started or just get better. Want to stay updated? Sign up for my mailing list to get updates when the book is ready to be released!
New community site for Javascript developers and user groups
Testing out the demand for a community site focusing on Javascript developers. When I was investigating the Javascript Magazine idea (still in the works – got some great contributors potentially lined up!) I realized that Javascript is everywhere, yet nowhere. There are few, if any, Javascript user groups or similar resources out there. There’s *loads* of books, and occasionally a few sessions at conferences, but no social ongoing stuff. So, I’m looking to start one.
Head over to http://jsusers.com and join up. The system is pretty open right now as to how it might be used. I’m anticipating people will use it to form topical or regional ‘groups’ to manage communication between themselves. That would be the best use, at least as far as I can tell right now. I’m using it to get some interest in a Raleigh area Javascript user group, and hopefully we’ll meet next month.
Groups for YUI, dojo, mootools and others would be great, as would groups for dealing with Javascript and particular technologies (Javascript integration with specific .Net or PHP apps, for example). Really, it’s open to what ever people want to make of it, but I’d like to see adhoc group creation.
Question? Comments? Leave them here or ping me at @jusers
I'm currently working on a book for web freelancers, covering everything you need to know to get started or just get better. Want to stay updated? Sign up for my mailing list to get updates when the book is ready to be released!
Line-item tipping
Was talking with my brother today and got on the subject of tipping (apparently it was on NPR today). We discussed the lousy experience we sometimes get, and there’s no way to indicate that in any way that anyone will notice. I’d like to suggest restaurants start “line-item tipping”.
When you come to leave a gratuity, you’d be presented with 3 lines:
_______ service
_______ food
_______ cleanliness (or ambiance, or something like that)
This would *easily* allow you to let the entire restaurant know – immediately – whether the food was good, the service was good, and the place was clean. Yeah, those stupid little survey cards are at some places, but I never trust they do anything with them.
If I get lousy food, but the server is still good, I’m tempted to leave the server a bad tip as a way of ‘sending a message’ but ultimately it’s really only hurting the server. Never going back to that restaurant is an option, but likely will hurt everyone.
The line-item gratuity would go a long way towards identifying the good parts of a restaurant on a real-time basis.
What do you think?
I'm currently working on a book for web freelancers, covering everything you need to know to get started or just get better. Want to stay updated? Sign up for my mailing list to get updates when the book is ready to be released!
Twilio – phone app proxy service
I had no idea how to describe Twilio, so “phone app proxy service” was the best I could come up with. It’s probably nowhere close, so let me explain what Twilio does.
Register for a Twilio account, and you’ll get a phone number. People calling in to your phone number will trigger Twilio’s server to hit *your* server; specifically, a unique URL you give Twilio. Your URL will return back some specific XML which instructs Twilio to play a message, say some text, or ask the user for some input (key or voice). Twilio will then send the user’s input back to your URL, which you can then parse and send back more XML to instruct Twilio which step to take next.
That’s it. You can build your own phone-driven service without investing in any hardware and very little software. Cost is 3 cents per minute, which is very reasonable in my view.
What sorts of apps would you build with such a service? I’ve got some ideas of my own, and will let you know if/when I build any of them.
I'm currently working on a book for web freelancers, covering everything you need to know to get started or just get better. Want to stay updated? Sign up for my mailing list to get updates when the book is ready to be released!
Are traditional object models enough? Can we evolve usefulness in OO models?
Just a quick thought here after looking at someone’s code I just stumbled on. This person had a “isReadOnly()” method inside of a generic “set” method which would allow them to determine if a property should be allowed to be modified or not.
It got me to thinking again how the traditional notion of “visibility” in OO is, imo, broken. Perhaps that’s going a bit far. It doesn’t address the day to day needs most developers have. I’d say more developers need some sort of a way of making properties “read only” than they do dealing with “public, protected, private” PPP notions which we get in traditional OO implementations. What PPP gives is all-or-nothing – you get full access to this property (or method) or you don’t get any at all.
Short port (I gotta run) – why do we not have some sort of default “read only” property modifier in OO implementations? The Groovy approach would be to create a setXXX() method that was empty, effectively overriding the default setXXX() method to not perform any manipulation at all. It’s not *bad*, and is pretty clear, but some modifier like, oh, I dunno:
readonly String name
would be useful, no?
I'm currently working on a book for web freelancers, covering everything you need to know to get started or just get better. Want to stay updated? Sign up for my mailing list to get updates when the book is ready to be released!
Javascript Magazine – gauging interest
I’m in the planning stages of a Javascript magazine, similar to the GroovyMag publication I’ve already got out. Before jumping in too deep, I’m looking to gauge interest in the idea. Are you interested in a monthly Javascript magazine? If so, click the link above and sign up. Or, just leave a comment below. :) Thanks!
I'm currently working on a book for web freelancers, covering everything you need to know to get started or just get better. Want to stay updated? Sign up for my mailing list to get updates when the book is ready to be released!
Java, JavaFX, mobile apps – my rant
Just had some random thoughts about Java, Javafx and mobile apps. I want to be wrong, but the recently launched JavaFX feels like ‘too little too late’. I was listening to some Sun podcasts and they did a good job of making me interested in JavaFX. When it was first announced last year I said “too little too late”, but wanted to give it another chance after it launched. I’ve been wholly underwhelmed by the demos and JavaFX rollout. Frankly, I’m not sure what they could have done to impress me, but this wasn’t it. I’m not entirely writing the whole thing off – I’d like to dig in to it some more – but coming up with a new language seemed a mistake, imo. Would have preferred they’d used Groovy (for somewhat obvious reasons) as their primary language, or perhaps even come up with a way to compile actionscript down to Java – that would have been an immediate boon to developers wanting to leverage their Flex skills in this new land.
On a related note, I’m wholly unimpressed by the “Java is on all mobile devices” argument that Sun and Java advocates advance when touting Java’s viability. It may have other benefits, but simply having Java *on* 2 billion devices, or is embedded in 4 billion smart cards, or whatever other massively large device numbers are trotted out, doesn’t do *me* as a developer much good.
I dare say it doesn’t really do *most* Java developers all that much good, because *most* developers won’t be writing stuff for those markets. And a market with 4 billion *locked down* hardware devices doesn’t necessarily even need to employ that many people – you’re cranking out commodity volumes at that point. You need a small number of highly skilled people (Java devs in that mix) but 4 billion Java devices around the world really doesn’t do very much for the Java developer marketplace *because those devices are locked down*. I’ve not used a mobile Windows device in many moons, but I have colleagues who’ve told me it’s pretty easy to write software for Windows mobile devices. That’s great, and is a good first step. The next step is distributing those apps. There may have been (or may be) some decent ways in the Windows ecosystem to do that on a public scale – I presume most Windows mobile apps written and distributed on large scales have been for corporate workforce-style apps – internal apps for companies (might be wrong on that). It seems that it wasn’t until Apple’s app store that the idea of just wirelessly grabbing apps from a variety of people (and being able to easily monetize those) that this market has been somewhat legitimized.
Bear in mind I did some limited Palm development back in the late ’90s, and there was (maybe still is?) a decent ecosystem there. But trying to become part of that world seemed *very* daunting. Trying to write any moderately complex Palm app was a relative nightmare, and then trying to get approved to distribute it was a whole ‘nother matter. I think I only personally know one person who did it, and that was me being in that world for over a year. In less than 5 months I’ve run across close to a dozen iPhone app developers, and they’re making some money at it.
Contrast that with Java and the Java mobile story. Yes, Java’s on a huge number of mobile phones out there. This means pretty much nothing for most Java devs because there’s pretty much no way for them to write apps and get those apps installed on those devices. The devices are locked down. Apple’s proved the viability of a model like this – 10s of millions of app installations every month, and developers sharing a piece of that revenue. Java – arguably one of the most widely installed systems ever – and who can benefit from that? Certainly not 99% of the developers out there who’ve spent their time investing in learning Java skills.
Sun *really* seems to be dropping the ball here. This isn’t a one time event here – I mean they’ve consistently dropped the ball for years when it comes to having a good mobile story (have they ever even had the ball to drop it in the first place?). I’m just not sure JavaFX will be enough to turn the mobile story around. From the marketing podcasts I heard, they seem to think so, but it’s their own marketing people, so I’m not sure I’d expect any less.
I'm currently working on a book for web freelancers, covering everything you need to know to get started or just get better. Want to stay updated? Sign up for my mailing list to get updates when the book is ready to be released!
- Get better clients!
- Make more money!
- Avoid costly mistakes!
