It’s the end of the world as we know it and I feel fine.
Lately I have had a TON of people telling me that Flash is dead. The writing is on the wall and all Flash developers might as well give up now. Apple has won. HTML5 has won. Flash is a dead platform and we might as well put all our effort into what the future is going to be.
Now of course I have a certain special love for the Flash Platform. I’ve grown up as a developer with it. I’ve been building on it from the very beginning. So I might be a little biased. But I might also have some pretty good insight too.
Ironically (or is it just coincidentally) I have been tossing around a post (my first after a long time of not writing) talking about my recent work with HTML/JavaScript. (I’m still going to do that one.) I too see the writing on the wall. But I think that maybe I’m reading something different than everyone else.
No big loss
Recently Adobe announced that it is going to discontinue the mobile Flash player. Oh goodness no! I don’t know a single Flash developer who has ever targeted the Flash player in a mobile browser. Maybe they exist but I don’t know any. As a user I hardly use it. Every now and then I’ll watch a Flash video on a webpage but if there is another option (YouTube app) then I’ll jump on that instead. So to be perfectly honest, I don’t see a loss there. I think Apple was right (and Microsoft in Windows 8′s IE, and many Android browsers that let you disable Flash by default, etc etc) to keep the web browsing experience lean.
Why not?
So if Flash developers don’t target mobile Flash player what the heck are they doing? Building applications. Real applications. For 10 years now I’ve been building REAL applications on the Flash platform. Sure some of it has been games (the type that teach kids to read good and add numbers and stuff). But most of it has been enterprise applications that need more polish than a collection of forms can give. Flex came along and made building those easier. AIR came along and made it even easier to distribute.
Today I can use the Flash platform and a very strong set of tools to very quickly build solid applications that run on all three desktop platforms. They look nice, they run well and they can get built quickly. I can prototype faster than your mom and if you want sexy pixels then I can make that happen too. On the Flash Platform.
Yes but . . . mobile!
But what about mobile Flash developers? I can build an app that runs in AIR and run it on many Android and iOS phones. Adobe said this when they announced the end of the Flash mobile player: “Our future work with Flash on mobile devices will be focused on enabling Flash developers to package native apps with Adobe AIR for all the major app stores.” So they are quitting working on what nobody really cares about so that they can focus on what is actually used and helpful. I say Awesome!
Is there an HTML5 equivalent? Sure there are a few people who have attempted an HTML app in the browser space (untappd for one) but the experience just isn’t the same as an installed app on mobile devices. I think that we have proven that, for now, installed apps are where it’s at. Native apps are probably the best to get the best performance but Unity does pretty darn well using its own run-time on iOS and Android. AIR is getting pretty darn good too and Adobe seems committed to continuing to make it better. So I still honestly feel that in the application space on mobile devices the Flash Platform is still a viable place to work.
To be fair, if all you’re looking for is a sales experience (because really everything breaks down to a sales experience) or some type of single-use experience then the mobile browser is where you need to work. And then HTML/AJAX is where it’s at. But for the small screen I don’t know that Flash or even the Canvas is what we should have ever been targeting.
Yes but . . . HTML5!
What a magic buzzword. When most people talk about the magic of HTML5 they’re essentially just talking about AJAX and good ‘ol HTML/CSS with a dash of well written JavaScript. People have been building great AJAX apps for years (GMail) and they have been building horrible app as well. HTML5 isn’t going to change that.
The reality is that HTML5 bring us just a few things we didn’t have natively in a browser before: video (which just hasn’t happened consistently yet) and a canvas. I know there is more but those are supposed to be the game-changing Flash-killers right? Now you can build these apps in HTML5 instead of Flash right? Isn’t the Canvas element pretty much like Flash?
People said similar things back in Flash 4 days. This new amazing thing was a game changer. We can build applications on this thing! Not just silly games but real applications! And they were right. We COULD build apps on that platform. But you know what? It was HARD. We had a cool new platform but it was awfully immature. Eventually Flash grew up and we can build awesome stuff with it. I expect the same thing from the current mash-up of buzzwords (HTML5/JavaScrit/CSS3/AJAX/Canvas/FlashKiller). We’ll be able to build some awesome stuff with that. Eventually. Once somebody builds some real tools to do so. And the Canvas matures (or just the usage of it) matures. I don’t expect it to take as long to mature as the Flash Platform did. Why not? Because all of the Flash rock stars are now working on the Canvas platform.
So . . . What about the writing on the wall? Didn’t you say you were working in this new platform too?
So you were paying attention. Yes. I’m trying to be as good at the browser as I am in Flash; Because I’m a UI developer, not just a Flash developer. It’s a great tool and I see the benefits of it in many spaces. I think that my skills as a Flash developer translate well and it’s kind of nestalgic. It reminds me a lot of my Flash 4 days. And because building stuff, really GREAT stuff, really interactive stuff, really head turning stuff in the browser is HARD. And hard is fun. It keeps me young.
I’m learning new tricks. But I definitely don’t see the Flash Platform going away anytime soon. 10 years? Maybe. But 10 years is a LONG time in computer land. And the browser and tools has quite a ways to catch up.
Nevermind
Well it looks like Adobe has done it to us again. Thanks for the heads up. After months of silence they have updated the API to work with the Facebook Graph API. This is after they closed bugs asking for GraphAPI operability as “wontfix”. And no word that I know of that they were going to get this current.
While there isn’t a tag in the repo it seems that they’re starting over with the versioning. The downloadable assets label the api as “Graph API v1″ so I guess that’s how it’s gonna be going. There is still support for old REST calls from the existing API so I’m glad to see that’s still in there. No longer are there strongly typed domain objects or commands though. Perhaps that’s for the best though. It is a difficult thing keeping something as mobile a target as Facebook current. I think that it’s going to make transitioning existing applications from v3 to “GraphAPI v1″ more difficult but if you want the new sexy you gotta jump on board.
For now I’m discontinuing work on my version of the API. I was just wrapping up some nice new functionality and about to write up some examples but I guess there really isn’t need now. As a friend of mine told me this morning “If Adobe has one who the hell would use yours?” Too true.
Instead I am going to put more work into the app that will actually USE this API so I guess there’s that huh?
I Graph it.
Well I’ve taken a few days and have done my best to evaluate the current state of the Facebook Flash relationship and the Facebook Programming world in general. It has admittedly been a while since I have done anything productive in the Facebook world so I had a fair amount of ground to cover.
State of the Flash Relationship
Boo. A lot has happened since I’ve been away and Flash really hasn’t kept up very well. There are quite a few solutions out there but personally there aren’t any that I personally would want to take into production with me. The REST API will probably stick around for a while; I don’t know that it can ever go away. The Graph API is gonna be huge but the transition certainly isn’t painless. Authentication has taken a great step forward on Facebook’s side but Flash hasn’t kept up very well. The solutions out there are fractured and many seem to take different approaches. There is a lot of work to be done.
OpenGraph
Yay! I think that Facebook’s Graph Protocol is going to be it. I think that this is how our meta-world will be built. Flash needs to get on this ship and RIDE it! I won’t write a lot about the OpenGraph API but my feelings for this are strong. I think that Facebook as got this bit figured out and that everyone else will eventually be following along.
Authentication
I don’t think that Facebook Authentication should be done in Flash. I just don’t. That was one of the hardest pieces of the first version of the Facebook AS3 library but I just don’t think it belongs in there anymore. I love OAuth2.0(ish). I think it’s a great improvement over how things were authenticated in the past. But if you’ve got a Flash App living in a web page that JavaScript will be running anyway and we should just be using that for our authentication needs. It really simplifies everything and gets us to “go” a lot faster and simpler.
Now for Air apps that could be a little different. I haven’t fully explored Air for Mobile apps yet but some authentication utilities might be needed there too. But my first pass is going to be Flash in the Browser and for that tools already exist to do the heavy lifting.
Stagnation
It’s a sad truth; the Facebook AS3 API has certainly stagnated this year over on Google Code. That makes me sad. I’m sorry to everyone about that. The man at Adobe that was behind this has since left the company and there really hasn’t been much attention paid since then. I have only myself to blame though. If I had wanted to make sure that the project kept going then I should have stayed more active in it. Instead I let work and family get in the way. Never again! Ok, just kidding. I only work on this stuff when I can and it’s definitely 3rd under family and “real job”.
To that end I’m going to try to be getting this project active over on GitHub. YourPalMark started this idea when he imported the existing API to a github project. He seems like a pretty busy guy and I have a feeling that his “real job” might have gotten in the way there too. I know that he has worked on a way to integrate the GraphAPI. Hopefully we’ll be able to integrate ideas. As well as the steps that Josef has taken to getting the OpenGraph into the AS3 world and Toby’s return to the JavaScript bridge. (I’m sure I’m missing some good attempts out there!) Let’s get all of these good ideas into one place! And let’s ESPECIALLY make sure that if somebody wants to add functionality and share it (as has been begged for in the Google Code issue tracking for the Graph API support) then it is ALWAYS available to the world. GitHub FTW!
Where I’m At
Right now I’ve kinda got things working. I started with the API as Adobe left it (which really wasn’t that far off from when they took it over from me) and re-factored a number of things to get it working with the GraphAPI. I’ve removed almost all of the connection/authentication stuff. I’m planning to re-add/re-factor what is necessary when I tackle Air support. All calls now use the Oauth session token (REST and Graph). All of the old REST calls “should” work (though I haven’t tested them all yet) and my plan is for the transition from the existing API to this new one will be smooth and painless while at the same time adding as much new functionality as possible via the GraphAPI. There is not yet any binary support (images, etc) in the Graph stuff yet; nor any specific commands. A generic “FacebookGraphCall” is the only thing available for now that you can format yourself to use MOST of the GraphAPI functionality.
I’m still butting my head against the IE show-stopping bug that Toby wrote his JS work-around for. I’m really hoping to avoid using JS as a bridge; it definitely cuts into speed and (I would expect) functionality. (At least it did in the old REST API when using the JSBridge). If you’ve got a way to work around this then PLEASE let me know!
You can find the project here. I can’t promise that it will live forever there. It’s still un-versioned. There are no build scripts. I’m just getting started. It depends on the as3corelib (for json processing) and the pbutils (for logging and my command framework). Both .swfs are (currently) provided for your convenience.
I’ve got a couple of great projects lined up that are going to need to use this API. I’ll be working on it quite a bit in the weeks to come. Please let me know your thoughts. If your interested in helping then I’ve very eager to talk to you.
Sample
P.S. If you’re looking for a REALLY simple example of how I’m using this api (and authenticating for it) then this might be helpful. I’ll have a lot more examples in the coming weeks as this thing gets going.
Facebook GraphAPI and OAuth2.0 Support
Just wanted to give a quick heads up to anyone who is interested that I’m looking into the lack of GraphAPI support in the “officialist” Facebook AS3 API. I’ve found a number of solutions out there and see that quite a few people have gotten some work-arounds and even some pretty good working solutions. My plan is to evaluate all of the solutions that I’ve found and hopefully work with the community to make the API stronger.
It seems that Adobe has stopped paying attention to our little project and there is definitely a need to get this thing active again! I have a pretty strong suspicion that the project won’t be living (or at least active) over on the Google Code page anymore. Everyone should probably be looking towards GitHub for the most up-to-date libraries.
More will be coming in the next few weeks. I’m sorry that this little project has fallen so far behind. The social programming scene is about to be a REALLY important place to be (as if it weren’t already).
Grails Post Complete
I started to do a bunch of writing about Grails and Blaze and the like. Then life got in the way. I had a lot planned but I just had too much work going on to complete the posts. I’m sorry that I left any of you hanging.
Fortunately somebody else has realized the awesome power the stack has and has started writing a great series on it.
If you are still interested in the Grails/Blaze/Flex stack then I highly reccomend you check out Sébastien Arbogast’s posts:
Part 1
Part 2