Bruce Eckel on Python, Java, Flex, and RIAs
In this post, InfoQ interviews Bruce Eckel to get his thoughts on the RIA landscape and to find out what he has been up to, as Bruce recently released a book he coauthored titled First Steps in Flex.
InfoQ started by asking Bruce what he has been up to lately:
Well, for the last 9 weeks I've been recovering from breaking a leg skiing. I've never broken anything before, so this was a new experience and it's included surgery, general anesthesia and various kinds of recovery therapies -- lots of new experiences. General anesthesia, in particular, I realized in hindsight takes a long time to get out of your system; weeks, really. So you sit around staring with your mind running at half speed, and when you finally resurface from all that you have this kind of new-found appreciation for consciousness. And after all that sitting around, you really want to go out and do things.
I was already asking myself "OK, what do I really want to do now," and breaking a leg has emphasized that. Just going along doing more of what worked before really isn't enough anymore -- I want to do things that are especially fun and interesting.
The main reason that I started writing a Python book was that I realized the consulting work that I've enjoyed the most has been with companies who have already decided they wanted to use Python (I suspect the same is true with other dynamic languages, but my experience has been with Python). One job was very challenging; every day it felt like I was in the old Soviet Union -- they didn't quite strip search us, but almost, and someone had to accompany me when I went to the bathroom. But the tech lead had insisted they use Python, so despite everything else I still had fun (however, I now know the difference between a company committing to Python and one strong and determined individual being able to push it through).
My general experience is that a corporate culture that supports the use of Python is highly likely to be fun and satisfying to work with. One that insists on using a language _because_ of the "directing" features (which people who are less politic call "bondage and discipline" features) is more likely to be driven to reduce risks than to explore and experiment. Risk reduction is certainly appropriate in many situations, but I've discovered that it's not what makes me happy. Rapid experimentation and exploring boundaries is what makes me happy, and in my experience companies that have chosen Python seem to be more prone to that, so those are the companies I want to work with now.
That said, I'm falling back on "what's worked for me in the past" in order to connect with those companies. Writing a book, and speaking at conferences. Definitely not original, but I haven't figured out any other ways to market myself so far.
Of course I continue to try to create Open Spaces events, and variants of those. These have also been extremely satisfying. After giving a seminar where I am speaking all week and frog-marching people through exercises (trying to make everyone learn at the same speed, which is silly, when you think about it) I'm exhausted and don't want to do it again for awhile. But when I do an Open Spaces event, I'm always disappointed when it's over and I realize I'm not doing another one the next week. I want to figure out how to make a lot more of those happen, because they make me happy. This is one reason James Ward and I wrote "First Steps in Flex," to help create a market for our "Flex Jams."
In the past few years I've been acting in the local theater. Crested Butte is filled with unusually talented people and we have an active theater group, and it's been a great challenge to be in these productions -- I've been in 5 or 6 so far. The last one was "Into the Woods," and I had never been in a musical before but ended up being cast as "Rapunzel's Prince." Together with "Cinderella's Prince" we had what was probably the sweetest duet in the play, which wasn't really fair since many of the other actors had to work much harder than we did. And my fellow prince had just finished acting school and grew up with voice lessons -- his mother was a diva in the London theater -- so I had quite a challenge to keep up with him. But the best part of the whole experience was working with people who were so serious and professional about participating in this amateur production. It gave me a little more insight about teams and how satisfying it is to be part of a well-running team.
In fact, I'm reading a number of books right now on software teams and ways that seem to help form good teams. Not that I'm thinking that I'm going to be a team manager anytime soon, but understanding teams is an important skill for a consultant to have, and one that I've been trying to get better at for many years.
One of the things that the theater does is put on 10-minute plays written by local authors, and I've done this several times. I've started writing a full-length play, and participate in a local writing group. I've taken various fiction-writing workshops over the years, and I've discovered that fiction writing is a much greater challenge than non-fiction writing (which is probably why there are only about 5,000 fiction novels published every year, and about 50,000 nonfiction books).
I have also started painting, although I've taken painting workshops for a number of years (I suppose taking good workshops is kind of a hobby as well; I learn from the workshops themselves but I also hope to improve my own events from these experiences). In the last workshop I took, the teacher emphasized that "it's not about using brushes on canvas, it's about putting marks on surfaces." I think this lowered the boundary enough for me to start just getting paint on stuff, without worrying about whether it was "right" or not. Just experimenting. And the one thing I've discovered is that it's a lot more satisfying to play around with putting paint on things than it is to be trapped, afraid that the moment you do anything it will be too imperfect to continue. I haven't mastered the zen of painting, by any means. My biggest problem is getting attached when something starts to look good, and being afraid to continue because I might mess it up.
One thing that recently happened is that I created the design for the Pycon 2009 conference T-shirt, which was a painting I did (an abstraction of the I-Ching hexagram 22, which represents "elegance/beauty"). Unfortunately I wasn't able to be at the conference this year, because of my leg, but people told me that seeing my painting on 1000 people was surreal.
I think these experiences are very helpful in the software world. Learning to be more experimental and to explore -- rather than sitting around pondering whether something will work or not -- helps move a project forward.
Bruce offered an overview of his recently released Flex book:
"First Steps in Flex" was coauthored with James Ward, who is an Adobe Flex evangelist. We wanted to write something that would make it easy for a programmer to learn Flex, so we made it small, with very short chapters. This keeps it from being intimidating; you look at it and think "oh, that chapter is so short. I could read that," and you think that about the next one, and the next one. The whole book is un-intimidatingly thin, and to do this we had to trim out anything the reader didn't absolutely need to know, and stick to the essentials. This way, people walk away feeling they can do something, but they're not buried in too much information. It took a lot of effort to distill Flex down to the essentials, but I'm quite happy with the result.
Then, InfoQ asked Bruce for his general impressions of the current RIA landscape:
I'm more and more convinced that the browser "standards" that we have stumbled into will NEVER become complete or reliable, or even usable. Look at CSS. Great in concept, but obscure as all get-out to program and inconsistent on browsers. HTML itself -- what a cock-up. There's no standard way to include headers and footers (yes, SSI but that always relies on a particular server configuration which you can't rely on), so people go to PHP, and then end up with something you can call "better than Perl" but only because it doesn't get you in trouble quite as fast (I use PHP, but very conservatively).
Bottom line: we need the intermediate layer between the browser and the RIA; the browser technologies will never get it right. Even generators like GWT just reduce the platform dependency issues, they don't eliminate them. Same with Ajax -- you'll still have to hand-tune the code so that it works on multiple browsers. Less work, but not work that I want to do at all. Why spend company resources on these problems when you can just put in an intermediate layer and completely eliminate the issue?
I'm still a fan of Flex, because the Flash player is supported on all platforms. Silverlight allows support on Linux, but I have no idea how far along that support is. And Microsoft has had a tumultuous history about non-Windows support. The latest version of Office for the Mac won't take macros from Windows, which was important to me and has caused problems for me and many others. Microsoft has all kinds of excuses for this, but who cares? You get screwed. If they decide that Silverlight support on the Mac should go away, they'll have reasons for that, too. Or if Linux is too big of a threat, they'll have reasons that you can no longer have Silverlight on Linux. Who cares? If you depend on it, you're out of luck. I notice Netflix went with Silverlight for their video-on-demand. So far I haven't been able to get it to work on Firefox on my Mac -- it will probably start working, but if it doesn't Netflix could start losing customers, and they've probably already lost the Linux customers. Adobe's a big company too, and they can also act capriciously, but they have a track record of supporting all the platforms, and Microsoft has an OS to push. Silverlight is well-designed and they've learned lots of things from Flex. I think the competition is great, and has stimulated Adobe to work harder. But if you come to me and ask whether you're better off with Flex or Silverlight, I'm going to say "why take the risk that Microsoft does another one of its marketing spasms and cuts you off?"
Next, Bruce was asked if he thought the industry's move to client side runtimes for user interfaces is a good thing:
Absolutely; I pretty much made the case above. But I forgot about JavaFX. At the JavaPosse Roundup 09, we did a little coding dojo, where Dick Wall created his "Flubber" application in both Flex (with the help of James Ward) and with JavaFX (with the help of Tor Norbye, who is on the JavaFX team). Conveniently this happened at my house, but I'm still in the early stages of recovery from surgery so I can't give all the details. What was impressive, however, was that he was able to achieve pretty much the same results in both languages. I think it was still a little easier in Flex, but I was quite impressed at the results in JavaFX. Also, the JavaFX looks a lot like ActionScript, but they've also added some clever language improvements, which I think will light a little competetive fire under the ActionScript designers, and that's a good thing.
Then, he was asked if Flex needs Java to be successful:
I think the Flex-to-Java bridges are important, and it's too bad Sun didn't support the development of one of these. For that matter, too bad Adobe doesn't either. There are open-source versions in the works and I think that in general we need more structure for commercial companies supporting open-source projects. Just a way for money to get to them, even if they don't hire someone or fully support it. I think we might see a lot more support for these projects if at least one person on a project could start making some kind of living from it. Anything that makes that process easier would benefit everyone.
Beyond Java, Bruce was asked what other languages he likes to pair with Flex:
Most of the projects I've built have used Python as a back-end to Flex. There are several approaches to doing this, but the Twisted library has direct support for communicating with Flex, and both are asynchronous so it's kind of a perfect fit.
Ruby also has support for communicating with Flex. I see dynamic languages as great backends because then you get the best of all worlds -- rapid development of really nice-looking UIs combined with rapid development of the business logic on the back end.
Finally, InfoQ asked if Bruce was doing anything with Java these days:
Occasionally consulting on design, that kind of thing.
I feel like the fourth edition of "Thinking in Java" really completed the book -- I've basically rewritten it four times now, and on the last time I think I got it right. So I don't plan to do another edition, but rather support the fourth edition with a supplement that will fill in important details and language features that have appeared since the fourth edition. But I hope to make this book a community effort, to be published electronically under the creative commons. Whether I can harness the community this way is another question -- it's what I'm trying to do with the Python book, so maybe I'll have a better idea of how to manage it by then.
You can read more of Bruce's thoughts on his blog.
John Altidor, Yannis Smaragdakis Mar 30, 2015