Archive for March, 2007

SWX Alpha 0.1e released with manual PHON serializer

SWX Alpha 0.1e is now available for download.

What's new in Alpha 0.1e:

  • Added manual PHON serializer.
  • Modified echo sample application to use the manual PHON serializer.
  • Moved the automatic serializer to the AutoPhpSerializer class. It's still there but you can choose whether you want to use it. I may remove this in future iterations.
  • Modified the SWX gateway to handle null values. The auto serializer was sending them over as undefined.

This release introduces a slightly modified workflow for working with SWX. I don't believe that it is more complicated though (and may even be clearer.)

Find out more about SWX Alpha version 0.1e and see a code sample of the new workflow on the SWX web site.

SWX: Still a good idea

Patrick Mineault maintains, after my post SWX: A good idea that SWX is still a bad idea. I still disagree. This is going to be my last post on the subject because it appears that we are just going to have to agree to disagree on this one and I would rather spend my time improving SWX and doing fun stuff with Flash rather than justifying the existence of my latest open source project.

In his post, Patrick states:

SWX is quite clever, but the implementation is not going to yield any net benefits for the community

I disagree strongly. SWX is quite clever thanks, but it wasn't merely an intellectual exercise for me. It was born out of the very real need that I felt for a simpler way to create data-driven applications in Flash. This is a real need that I have and I am sure that others share this need. As such, by fulfilling this need, SWX *is* going to benefit the community. For other benefits of SWX, see my previous post (SWX: A good idea) in which I outline the advantages of SWX on a more technical level.

As for my statement that SWX is a hack, I stand by that, and I think other people agree.

Patrick is right. SWX *is* a hack and I thank him for the compliment.

So what is a hack, actually?

According to the Merriam-Webster Online Dictionary, a hack is "a usually creative solution to a computer hardware or programming problem or limitation". Yes, SWX is definitely a hack.

And I hope it gets Flash developers to hack -- "to write computer programs for enjoyment" as the word means as a verb -- and to create more hacks.

SWX is meant to make it easier for you to hack even if you don't have a degree in computer science. I thought that was the whole idea behind Flash in the first place! Where did we lose our way?

Patrick mentions that there are other people who agree with him. The "other people" currently appears to be comprised of a one Theo Hultberg who states in a blog post titled On SWX that SWX "is not worth a second look". Fair enough -- we are all entitled to our opinions and the number of looks we give things -- but then he proceeds to demonstrate a lack of understanding of how SWX works and simultaneously questions my word by stating:

partly because of the questionable implementation of the client side deserializer (which may or may not be just a temporary version")

If Mr. Hultberg had actually read the documentation for SWX -- instead of hastily shutting his eyes to avoid a second look at something new and different -- he most likely would have known that one of the key features of SWX is that there is no client-side *deserializer* as your data loads in a SWF so what he meant to say was *serializer* in the quote above.

I have already promised that there will be a manual serializer and Mr. Hultberg has no basis to question my integrity by stating that I "may or may not" deliver on this.

Unfortunately, it gets worse from there as Mr. Hultberg succeeds in the questionably-enviable accomplishment of managing to personally insult me *and* question my competence as a programmer in a single sentence:

I wouldn’t hire people who wrote code that looked like that, and I sure wouldn’t use their frameworks.

I hate to say it but it appears that Ludditism is alive and well and living in the Flash community.

Making a public comment that contains such a generalization can only make you appear like a fool.

Mr. Hultberg, you couldn't *afford* to hire me in your wildest fantasies, much less reality, so the first part of your statement is a moot point. Secondly, your statement assumes that there is one use (and one use only) for Flash and that is to build large enterprise Rich Internet Applications. That couldn't be further from the truth if it had been catapulted to the end of the galaxy by an electron accelerator. Unfortunately, however, it does show us the ugly face of elitism that I myself have been guilty of perpetuating to a certain degree without ever meaning to.

Before I go into detail on this, let's just state for the record a fact that bears repeating:

You do not need to be a computer scientist to make amazing Flash stuff and to have fun with Flash.

And, furthermore, there's nothing wrong with having *fun* with Flash. And there's nothing wrong with hacking something together quickly and experimenting.

Do not let the fear of writing "bad code" or not architecting something "perfectly" ever stop you from doing things. There is no such thing as "perfect" in what we do. It's all part of a learning process and you have to be prepared (or even look forward to) building things, throwing them away and starting again. Knowledge of design patterns and good practices is very important when working on large applications that have long lifetimes and are maintained on by multiple developers. But that's not the only use-case for Flash (in fact, I'd argue that that's not even the main use-case for Flash.)

If anyone tells you the opposite, you should be well within your rights to tell them to kindly remove the baseball ball that they must have accidently sat on because it can't be good for their health and is probably going to make it uncomfortable for them to read the thick Java manual they carry around to hide their insecurities.

I love design patterns and I am genuinely passionate about application architecture and development processes. In fact, I consult about this regularly with enterprises of all sizes -- it's what I do for a living. But I am aware that Flash has a wide range of applicability -- everything from linear animations to banner ads to games -- and that preaching a One-Size-Fits-All approach based on the merits of a single workflow and methodology above all others is a fatally-flawed, fundamentalist position to defend.

Looking at Mr. Hultberg's About page, you see that in the past he was "a Java web application developer" who "studied software engineering". It goes on:

My aim is to introduce proper system architecture and object oriented design to the ActionScript community, something that I find is lacking.

Let me tell you who Mr. Hultberg is with that statement: He is the white man come to educate the natives with the Word of the Lord.

Hallelujah, brother -- thou shalt be saved from the sins of Flash by the cleansing light of Java!

You see, Flash developers are an ignorant bunch who live simple lives. They don't know about design patterns and wouldn't know a Mixin from a Front Controller if one was to hit them in the face on a windy afternoon. In fact, it's a miracle they ever get anything done. They must be saved from themselves. But don't worry, because *civilization* has come to the Flash platform as Mr. Hultberg and his merry band of Evangelical Java bishops bring us the truth of The Light.

WTF?

Who died and elected you Pope, Mr. Hultberg?

(I have to point out here that I have nothing against Java developers in general -- or any other developers, really. I've developed in Java myself and I've used and continue to use a variety of programming languages and technologies -- each of which has its own use cases, advantages and disadvantages. It is the elitist attitude I am describing here that certain developers have that I find harmful.)

I have a feeling that people like Mr. Hultberg would love to see Flash become Java because that's what they know. Sometimes when you only have a hammer, everything looks like a nail. But Flash is not Java. It has its own essence and that essence is beautiful. Instead of trying to repress its true nature, we should find creative ways of letting it shine. I've seen too many Flash projects jeopardized because important design decisions were made by Java developers. I've seen frameworks created that try to mimic or recreate Java in Flash. Heavy, scary frameworks that scare away Flash developers. Unfortunately, many Flash developers are intimidated by these people who pass themselves off as "real programmers" because they have server-side programming expertise.

Flash, however, is not a server-side technology and your server-side development knowledge will not transfer to it verbatim. In fact, the actual complexity of server-side systems, for 90% of what makes up a web application, is much lower than the complexity of the client.

On the server side, you build interfaces that talk to other computers. They talk in pre-determined, unchanging protocols. Things are predictable, you can unit test them to death. On the client side, however, you are building interfaces that talk to a human: An unpredictable, complex creature that may just be scratching his balls with one hand as he uses your lovingly crafted interface with the other while simultaneously devoting 73% of his attention to Carmen Electra's rack in the trailer of I Want Candy that's blaring on his TV screen. (In no way is this based on personal experience -- I don't even watch TV!) :)

Is it any surprise that building usable user interfaces contains far greater inherent complexity than getting two computers (or two computer programs) to talk? Is it any surprise that, given the attitudes of certain "real programmers", the complexity, effort and expertise involved in creating user interfaces is underestimated time and again? Is it any surprise, then, that we have such a high failure rate for projects in our industry?

Flash is a client-side technology and there is a wealth of specialized client-side knowledge that Flash developers have that server-side developers do not. It is often the case that Flash developers will respect the work that server-side programmers perform but it is rare for that respect to be mutual. And the only reason for it not to be is because of a certain elitist superiority complex in these people, coupled with a dangerous ignorance of Flash.

It may surprise Mr. Hultberg to know that I've built my share of large enterprise RIAs. I started doing so in Flash 5 when Branden Hall, Keenan Keeling, Charlie Cordova and myself built the Flash front-end to a virtual school. We had to write our own event dispatching systems, components, etc. -- all things that were later added natively to Flash MX. I've been around, Mr. Hultberg and something tells me I've been doing Flash for a little longer than you have, so read on.

With each version of Flash, we have been moving further and further away from the simplicity that made Flash such an approachable tool. The Flash IDE was never meant to be a tool for building enterprise applications. Unfortunately, before Flex, it was the only major IDE available for the Flash Platform and Macromedia tried to make it do everything. In the process, it began to struggle to do anything particularly well. Animators were left behind (I know animators that still use Flash 5 because it supports their workflow better), designers were snubbed (do you remember the removal of Script Assist in Flash MX 2004) and all for what? So we could appear more "grown up". And what did Macromedia take as a grown up role model? Nothing if not the heaviest, most bulky, over-hyped and under-delivering programming language I know: Java.

(And by I know, I really do mean I know Java and I have developed server-side applications using J2EE.)

Yes, they tried to make Flash look more like Java to attract Java developers and it worked. Many prominent voices were quick to declare that with ActionScript 2, ActionScript had finally become a "true" object-oriented programming language. That's the biggest crock of uninformed bullshit ever. Classes are syntactic sugar in ActionScript 2 -- everything gets pre-compiled down to ActionScript 1. ActionScript is a *prototype-based* language and has always been object-oriented. You do not need to look like Java to be object-oriented. You do not need the compile-time concept of *classes* to be *object*-oriented. In fact, you could argue (and rightly so) that a language that only has objects (not classes) is *more* object-oriented.

In fact, this misconception continues today with ActionScript 3. Java developers are sometimes quick to hold AS3 to their chests as their own. AS3 couldn't be less like Java if Java lost 400lbs in 30 days by eating nothing by Subway sandwiches. AS3 is an optionally-typed *dynamic language*. In essence, it is far closer to Python or Ruby than Java. Don't let the syntax fool you.

Thankfully, the release of Flex meant that Flash could drop the burden of being the primary RIA tool for the Flash Platform (alongside all its other roles.) Starting with Flash 8, we have begun to see it focus more on some of the core areas that had fallen into neglect and I hope that this trend continues in future releases as well.

You know what the ironic thing is? I have spent the last three or four years talking about best practices, pattern-based development and development processes at conferences around the world. The framework I wrote that Mr. Hultberg says he wouldn't use (based not on its own merits but on the sample code he skimmed for SWX) is Arp and it is being used around the world by people whom I would consider to be cornerstones of the Flash community -- some of the best developers I know. And I do believe that an understanding of design patterns and best practices is essential when working in teams and on large projects. But they can also be harmful if not presented correctly. Let me tell you how:

As I mentioned earlier, I have been giving talks about pattern-based development, best practices, and agile development processes for quite a few years now. Generally, I feel that these talks have been very beneficial for my audiences. I have tried to expose them to concepts and workflows that they may not have heard before and these will no doubt help them when working in groups and on large projects. However, what I failed to do in these talks, which I now wish I had, was to wrap everything up in a huge caveat: Knowing all of this is great but don't ever let it stifle your creativity.

I have seen developers stuck in front of their computers, unable to start working on a project because they are afraid to make a mistake. Because they have heard that there are better ways of architecting things, "best ways" perhaps even, and they are not sure if what they are about to write is going to be "correct".

I was devastated when I first saw this (and I've seen it many times, at different levels, in many different developers since). There I was, talking about agile development and pattern-based programming that was supposed to make it easier for multiple developers to work together, communicate and talk about code. There I was, trying to spread best practices that were supposed to make developer's lives easier. All positive, dynamic things that were meant to improve the daily welfare (and happiness) of developers. And there I was, seeing that it could sometimes have the opposite effect: Stifling creativity, creating fear and uncertainty, leading developers to think along the lines of "right" and "wrong" rather than simply creating, experimenting and having fun.

(There is never a "wrong" in development -- it's a continuous process of learning. There are no bugs, only feature requests.)

So, yes, patterns, knowledge of good practices and agile development processes are important but the most important thing, above all of these, is to not be afraid.

Don't be afraid to create, experiment and make mistakes. Remember, there are no mistakes -- it's all a process of discovery. Go ahead: write sloppy code, then throw it away and write it better. Throw stuff on the timeline, try different ideas, break things, then put them back together again. You can always tidy things up later. Don't let fear of imperfection lead you to inaction. There is no such thing as perfect. Do something, anything and then evolve it. Don't think too much about it or you may end up only thinking about it. Do, make, share, evolve!

Above all, and this is the really important bit: have fun! It's OK to have fun! And don't let anyone tell you otherwise.

I hope SWX helps you have more fun with Flash. That's what it's about. And that's why it's necessary.

New version of SWX released - supports PHP 4

Update #2: SWX Alpha 0.1d is now available for download.

What's new in Alpha 0.1d:

  • Fixed bug with the SWX gateway that threw script errors for incorrectly formed requests. This bug was introduced with the addition of GET functionality in 0.1b.

What's new in Alpha 0.1c:

  • The example FLA is now saved in a format that can be read by Flash 8 (oops, sorry + thanks Paddy for alerting me to this!)

What's new in Alpha 0.1b:

  • PHP 4 and PHP 5 support. Tested with PHP 4.4.2 and PHP 5.1.4
  • Added GET support to the gateway. You can now call the gateway with both POST and GET

This release brings PHP 4 support to SWX. I've only tested it with 4.4.2 and 5.1.4 so if you do test with a different version of PHP, please let me know how it goes.

Download SWX Alpha 0.1b from the download page at swxformat.org.

SWX: A good idea

I just read that Patrick Mineault thinks that SWX is a bad idea. Although I have the utmost respect for Patrick and I love and support his work, I respectfully disagree with him. SWX is a good idea and here's why.

(I started responding to Patrick's post in the comments on his blog but it got too long so I'm posting it here instead.)

The followering are the main points Patrick makes in his post, along with my counter-points:

Now my first point is that SWX reinvents the wheel, and for no good reason. Let's list out the various ways to do asynchronous data communication in Flash. We have LoadVars, XML, Remoting, JSON, SOAP, XML-RPC, and PHPObject. One solution seems more than enough for this very simple tasks; adding another one to these 7 seems like a complete waste of time.

I remember when Flash Remoting came out that, for a long time, people would make the same argument against it: Why do we need another way to exchange data? Why did they re-invent the wheel? And the answer is the same now as it was then: We need it because the existing methods do not meet the needs of certain people.

If we were to accept Patrick's argument at face value, there would be no reason to go beyond LoadVars and we could throw XML, Remoting, JSON, SOAP, XML-RPC and PHPObject away, labeling all of them as redundant. After all, as I mentioned in my talk at the LFPUG last night, the core concept at the heart of building data-driven applications is a glorified form of automated copy and paste. We are moving information around from one place to another. In place of trucks, we use pipes to move our data. But it's transportation, not rocket science. So anything you can do with Remoting you can do with XML and LoadVars. Based on this argument, Remoting, XML, JSON, SOAP etc. all re-invent the wheel. But that's not true. Each has its specific strengths, weaknesses and use-cases. As does SWX.

Of course, it wouldn't be if in fact SWX gave some mighty good advantages over all the other solutions. To my knowledge, however, the only positive advantage to using SWX is the ability to use getBytesLoaded and getBytesTotal, which isn't available, in, say, Remoting.

SWX does have several mighty good advantages over all of the other solutions, above and beyond giving you the ability to display a determinate progress indicator as mentioned by Patrick. (If that was the only advantage, as much as I like determinate progress bars, I surely would not have invested as much time and effort into creating this as I have!) :)

Here are just a few advantages I can think of off the top of my head that SWX has over other methods:

  • It's simpler to use.
  • Data is deserialized twice only as opposed to four times.
  • You don't have to learn a new API and can reuse your existing knowledge.
  • It is useful in mobile applications with limited processing power
  • The final downloadable bundles of SWX will contain everything you need to get up and running (you don't need to buy or download additional tools).

I want to elaborate on some of the above points, starting with the advantage of having two deserialization steps instead of four. To illustrate the point, I'll use the model that Patrick presents in his article on Clearing the FUD on amfphp’s speed versus JSON and XML (which is quite ironic since I'm clearing the FUD about SWX here!) In it, Patrick accurately states the following:

In most any RPC model, there are the following steps:

  • Serialization of the request on the client-side
  • Uploading of the message to the server
  • Deserialization of the request on the server-side
  • Dispatching on the server-side
  • Serialization of the response on the server-side
  • Downloading of the message to the client
  • Deserialization of the message on the client-side

In most any RPC model, that is, except SWX. Let's look at how the above list looks in SWX.

Steps in SWX:

  • Serialization of the request on the client-side
  • Uploading of the message to the server
  • Deserialization of the request on the server-side
  • Dispatching on the server-side
  • Serialization of the response on the server-side (i.e., assembly of the SWX SWF)
  • Downloading of the message (i.e., SWF) to the client
  • Deserialization of the message on the client-side

Straight off the bat, we remove the deserialization of the request on the server as the PHON object that is sent over is evaled, following security checks. The big advantage, however, is that we also remove the deserialization step on the client side because your Flash client is receiving a native SWF. There is no deserialization. The moment the SWF is loaded, it is ready for you to use. Just access the data structure and you're off.

Among other things, this means that there's no equivalent of the Flash Remoting Mystery Time. Once the SWF is loaded, the data structure is immediately available for you to use. Any sort of deserialization on the Flash client is going to use up processor cycles and SWX, by design, is the least processor intensive method possible since it is SWF bytecode and that's as native as you get in Flash.

Of course, time will tell how SWX compares with the other options in terms of performance, etc. but my gut tells me that a fully optimized SWX will compare very favorably indeed. It is, of course, not fair to compare it on these grounds currently as we are at a very early alpha release (think: one step removed from a proof of concept) and it is currently not optimized in any way. Most importantly, though, SWX is not in a pissing contest with other formats. It is one alternative, it is simple, and it has very valid use cases. In fact, one of the first things I am planning to do is to show people how SWX can be used alongside Amfphp and the single-package distributions of SWX will actually include Amfphp (I love Amfphp, Patrick, you know that!)

If you look at the sample code on the webpage . . . The first thing you'll notice is that dataHolder is a movie clip on Stage. That means that either you must place this empty movie clip on stage manually, or you have to use createEmptyMovieClip first. Of course, if you do the latter, you have to think about depths and whatnot. The second thing you'll notice is that there is an onEnterFrame. I thought the whole reason we dropped the use of onEnterFrame for polling a movie clip is that we had all sorts of crazy issues with that, including the difference between 0 and 4 loaded bytes.

I think Patrick is missing the point here. The key thing here is that Flash developers understand movie clips and know how to work with them. That sample code is purposefully simplistic. Of course, I will be releasing utility classes that abstract that away from you if you want to use a highler level API but the important design consideration here is that you *don't* have to learn a new API to use SWX. That's the beauty of it. You can use your existing Flash knowledge to easily create data-driven applications. And for those of you who *want* to have a higher-level interface, you'll have one. But it won't be forced on you.

Also, there is nothing wrong with using an enterFrame handler. The initial states (negative, etc.) tell you the various states that the load process is in and are actually very valuable for presenting accurate status information (is it waiting for data, receiving it, etc.) And, of course, you *can* display a determinate progress bar when you start loading the data. Apart from the usability advantages of doing so, it's just plain cool! :)

The third point is that the PHON serialization that is used relies on a prototype hack . . . So we hack toString in Array, Object and even (gasp!) String. I am not even to bother to expand as to the myriad ways in which I think this is a bad approach, but you can imagine the argument.

Ah, I just knew that people would get stuck at this point :)

Just to make it perfectly clear: The PHON serialization in SWX does *not* rely on a prototype hack. The current alpha of SWX happens to contain the automatic PHON serializer as the only option. I just didn't have the time to also release an alternative utility class that doesn't rely on extending the prototype object.

As I mentioned in my talk at the London Flash Platform User Group yesterday, this automatic workflow is very cool but you would be right to have concerns about object pollution if you use this method. Whether or not this will be a problem depends on your application. For simple apps, it should be fine. But if you're uncomfortable with it (or if you're using the toString() methods of the Object, Array or String classes for other purposes in your application), then you won't have to use the automatic PHON serialization method and you can use a manual method instead. That will involve one extra line of code:

org.swxformat.PHP.serialize(dataHolder.data);

To say that PHON serialization in SWX *relies* on a prototype hack is incorrect. The automatic PHON serialization workflow happens to be the only one I had time to implement in time for the initial launch. The manual method will follow very shortly (in fact, I think I'll get it into the next release.)

The fourth issue with this hack approach is that it is not going to work in AS3, either in Flex or in Flash 9. For one thing because you can't hack prototype, for another because the AS3 bytecode is different from the AS2 bytecode.

The current workaround to using SWX with AS3/Flex 2/Flash 9 is to use LocalConnection. In fact, this is what the SWX Analyzer (which is a Flex 2 application) does. However, this is far from ideal. I haven't even looked into how SWX may be implemented in AS3 at the moment but it is on the roadmap. Patrick is correct in that it will require a re-write of the PHP-based SWF assembler to use AS3 bytecode but there is nothing in it that is inherently impossible. And, as I outlined above, nothing in SWX relies on a "prototype hack".

SWX also had the disadvantage of being impossible to debug in Charles or ServiceCapture. Aral did a nice job with his Flex debugger, but why bother when you have native tools in your hands that do the job really really well.

I fail to see how having a free, built-in debugging tool can be perceived as a disadvantage. Surely, Patrick means that SWX has an *advantage* here! :)

When working with Flash Remoting, you need to purchase a separate tool to debug your application. Both Charles and ServiceCapture are commercial applications that you have to pay for and purchase separately.

Charles costs $50 for a single user license, and ServiceCapture costs $34.99.

SWX with the built-in SWX Analyzer, in contrast, costs $0.

(And it comes in the box so you get everything you need in one download.)

On a personal note, I found Charles to be highly annoying when I was evaluating it. Both the cumbersome interface and the constant "buy me now" nagging in the evaluation version. However, I do love ServiceCapture and I've bought multiple licenses for it over the years. It is far more than a remoting debugger (although it is wonderful for that purpose) and there is no reason why you cannot use ServiceCapture alongside SWX for its other features, such as the very useful network bandwidth throttling feature.

I could go on: SWX doesn't have anything for batched calls, or for typed objects, and I can hardly see how it could be put to use on a serious RIA.

It's true that SWX doesn't have batched calls, typed objects (yet) and that it may not be your first choice for a "serious RIA". But it's not for "serious RIAs". In fact, I'm fucking sick of "serious RIAs" and look forward to using SWX in fun projects that are in no way serious :)

You might argue that SWX is not meant to be used in RIAs, it's better for smaller projects, but that's why we have LoadVars and XML. Honestly I really don't see the point.

The whole idea behind SWX is that it is far easier to use than both LoadVars or XML that it is in a different class altogether when it comes to simplicity.

With LoadVars, you need to serialize your data into some custom format and then deserialize it yourself. This is a lot of useless plumbing code that no one should have to write. I had to write routines to deserialize complex arrays before but that was in Flash 5 when we had no other choice. Life is way too short for you to spend it writing this sort of useless code. All it does is bloat your application and take time away from actually creating your application and having fun with it.

XML. Where should I start? Have you ever worked with XML in Flash. It's not pretty is it? Until E4X in AS3, using XML in Flash was akin to pulling teeth without anesthetic. Another helping of firstChild, lastChild, bastardChild anyone? No, I didn't think so. Of course some people used helper classes that mixed in object-style look-up functionality to XML structures but how many people, really, even knew about these. In my experience, very few. Many people I see end up converting the XML structure into an object structure and then using that. Umm, but that's exactly what you get with SWX without doing any work whatsoever -- a native Flash object, as complex as you like, delivered to you piping hot in a tasty SWF shell! :)

SWX offers a huge advantage over both LoadVars and XML: simplicity. And the fact that you don't have to worry about serialization and deserialization.

In conclusion, I just want to state that SWX definitely has valid use cases: They're just not the same as those for Amfphp.

SWX, first and foremost, is built with an overriding focus on simplicity. It may be 2007 but, unfortunately, we still don't have an intuitively simple way to create data-driven apps in Flash. The closest thing we have is remoting (and I'd argue, Amfphp is the simplest one to get up and running with) but too many developers are still afraid to dive into the depths of even that. With SWX, you don't need to know anything new to get the advantages of Remoting without the extra hassle.

If you're building a mashup, or a FlashLite 2 application, take a look at SWX. If you want to have fun with Flash and create data-driven applications without the hassle of learning new APIs and downloading extra classes and all that unnecessary stuff, then SWX may be the right choice for you.

Like anything new technology, it will take a little time for it to mature. As I've mentioned in several places, it is currently not optimized in any way so this really isn't the time to be running benchmarks on it with other, mature technologies that have been around for ages.

SWX is growing and changing daily and I hope you will be part of its story. Pretty soon it will be up and running and getting up to all sorts of mischief and then we'll really start having some fun! :)

Don't forget that SWX is a tiny, new-born baby right now. It just opened its eyes to the world yesterday. Let's give it a chance instead of trying to strangle it in its cradle.

Rediscovering fun

Rediscovering fun and SWX at the London Flash Platform User Group

Yesterday was a big day (25 hours would you believe). I finally revealed the tangent I've been working on for the past two-and-a-half weeks or so: SWX -- a new data exchange format and related workflow and tools. I also presented a brand new talk I'm evolving titled "Rediscovering fun" at the London Flash Platform User Group meeting in London (and had great fun doing so!). I've decided that this is the talk I'm going to evolve at the conferences I'm attending this year (which reminds me, I need to tell them that ASAP!)

Today, I'm back to working on SWX (what, you thought it was over with the initial alpha release? Far from it!) The first major show-stopper I'm tackling is the lack of PHP 4 support and, as far as I can tell, it was down to my using a *single* PHP 5 function (*doh!*). Looking at it last night and a little earlier this morning, it looks like the problem is slightly hairier due to a bug with the unpack() method in PHP 4 (and some versions of PHP 5, apparently.) I should hopefully have that fixed in the next ten minutes or so and, following testing on both PHP 4 and 5, I will issue the SWX Alpha 0.1b release once that's done.

I also wanted to thank you for your kind words of support and encouragement, both on the blog and in personal correspondence. I'm so happy that so many of you find SWX as exciting as I do.

SWX: A new data exchange format for Flash.

SWX: The SWF Data Exchange Format

You don't need to wonder what project codename The Tangent is any longer. The tangent is SWX!

SWX stands for SWF Data Exchange Format. It's a new way of working with data in Flash that uses simple SWF files to exchange data. SWX is the natural, native way to get data into Flash: You loadMovie() your data!

And you receive your data in a tasty SWF shell. Yum!

If you want to find out more, head on down to the SWX homepage (swxformat.org) and read the introductory article on SWX.

I just finished uploading the initial release and I opened up the SWX SVN repository for read access. You can either check out the latest version from there or download a .zip of the release from the SWX download page.

Don't forget that this is a very early alpha. Read the known issues and limitations section in the SWX documentation for more information.

I can't tell you how excited I am about SWX and I hope that you will be too after you read up on it and try it out. And please let me know what you think by leaving a comment either here or on the SWX homepage!

Here's to SWX! I hope you enjoy using it! :)

Yesterday: Apollo on Boagworld, Apple TV, giving in to the iPod and the Adobe CS3 launch

I spent most of the morning yesterday writing documentation and examples for The Tangent. There's One More Thing (tm) I want to try and get in there before the launch late today/tomorrow so I'll be working on that today.

It's Apples and CS3s

We also went down to London Pete and Relly to attend the CS3 launch party but, of course, we stopped at the Apple Store on Regent St. first. Bad move! :) I left with an Apple TV (see pictures of the unwrapping ceremony). We're going to use it tonight to watch the season finale of Battlestar Gallactica with Pete and Josh. Oh yes, and I finally gave in to my iPod-free existence and got a (RED) iPod Nano. Actually, I first gave in a few hours prior to that moment at the Solutions store in Brighton where I got a silver one but that baby's going back today.

The CS3 launch party was... umm... well attended! And the booze flowed like water. Of course, I forgot to take my phone with me (*doh!*) and couldn't post any pictures. They had little cakes with the periodical table symbols on them and we had great fun trying to guess what Ct and Sb were (needless to say, a four-letter word was suggested for the former and son-of-a-bitch was among the suggestions for the latter.) I still can't believe the branding -- what a mess!

At least the boxes had slightly higher production values. Although no one could tell what they were supposed to signify. Oh well, I guess it's what's inside that matters...

There was a presentation but it was too low to hear at the back so, of course, we kept talking which made it completely impossible to hear. (There's a chicken and egg in there somewhere but I'll stop looking for it now. Though the egg may be chocolate -- yum!) I did catch bits of it: One of the presenters, for example, professed that he'd been at Adobe 20 years and that the ladies wouldn't believe him if he told them he was 40. I have no idea what else he was talking about but I'm assuming it had something to do with CS3. Next time, it might be an idea to use a more powerful PA system.

The various applications were on show at the party and it is a good looking bunch. I've got my eye on the Master Collection which contains something like a gazillion Adobe applications *and* a Tickle-Me-Elmo toy. Fanfuckintasticlicious!

No, really, why are there fifty zillion different bundles? Adobe, don't become Microsoft. Tsk, tsk.

I still want the Master Collection. Do I have to be wearing leather to buy that? "Who's your daddy, Photoshop? Uhuh, that's right!" :)

(This blog post originally had purpose and direction and may do so again at some point.)

BoagWorld Podcast

Ah, yes, and the piece I recorded on Apollo for Paul Boag's Boagworld podcast went live in yesterday's show titled Neverending Beta.

I even listened to it on my new Nano. Boy do I feel megahiptacular!

Today, today, I love you, today!

So without further ado, I'm going to get back to working on The Tangent...

The Tangent: Now with 100% extra security!

I wanted to get at least a minimum level of security implemented on the server side for the alpha release but I believe I've gone beyond that. In fact, I'm pretty sure that what I just implemented should be all that's needed, going forward. (One of the great things about open source is that it will be reviewed by a large number of people so if there are any issues I'm sure we'll catch them and fix them.) As far as I can see, The Tangent is now secure :)

I'm now heading back home to record a piece on Apollo for Paul's Boagworld Podcast but I'm going to get right back to working on The Tangent after that.

I'm close ... so close! :)

The next steps are to keep working on the web site, create the final versions of the first examples, put those and the analyzer up and launch the website with the public announcement, demos, etc. That should happen tomorrow, with the initial early alpha release going live on Wednesday.

If you're interested in seeing me present The Tangent (and talk about "rediscovering fun" and life in general), come down to the LFPUG in London on Thursday.

The Tangent: Roundup

Following Mike Davies's spirited uncovering of the domain name that The Tangent will be hosted at (http://swxformat.org), here's a roundup of everything that's currently public about the project, including some new bits of information, ahead of next week's official announcement:

  • I started it because I'm not happy with any of the existing methods of working with data in Flash. I find them unnecessarily complicated to work with and I believe that this is scaring developers Flash developers (hint) away from building mashups, experimenting and having fun with data-driven applications in Flash. (The other formats have their uses and The Tangent won't replace them for every use case -- and will work alongside them also. You'll be able to use it in a complimentary manner with AMFPHP, for example.)
  • My overriding design focus with The Tangent is simplicity. Everything about the project will reflect this, from the web site to how the project itself is deployed and distributed and the documentation and supporting materials. The Tangent is going to be the easiest way of working with data in Flash.
  • Next week's release of The Tangent is *very* early alpha - it will creak, it will break, it will throw its toys and generally be a nuisance — but it will nevertheless be very, very cool!
  • And a new tid-bit: Initially, PHP will be the only server-side technology that is supported. In further iterations (and with community support), we should see support for other server-side technologies such as Python, Ruby and Java.

I spent some time today making the analyzer component (one piece of The Tangent project) all-beautiful-and-shiny-like. I'm very biased, of course, but I like to think that it's a lovely analyzer, as far as analyzers go (I decided it's not really a debugger and hence the name change). I hope you'll agree when you see it next week.

I will be releasing the web site, full information and the initial alpha over the course of next week. The alpha will be out prior to my talk at the LFPUG on Thursday and you can be sure that I'll be presenting it during the conference tour that I'm going to be embarking on starting in April (May's totally crazy -- something like four conferences, maybe more! More on those later!)

Thank you all for the interest you've shown in this and for your support. It's going to be worth it -- I can't wait to reveal The Tangent and to work with you to develop it into something that's really useful to us all.

Here's to the most amazing community on the planet! Go Flashers! (Yell that in public, I dare you!.. umm, does a blog count?) :) Love you guys! And I hope you'll love The Tangent! :)

The Tangent has a(n) debugger analyzer!

I just got the debugger analyzer for The Tangent working. It took a little eye-crossing bit-twiddling which I had a lot of fun with and it was lovely to see it work when it finally did.

Tangent Tease So, here's the tease of the day -- a tiny slice of the s _ _ f _ r _ a t . org page. (See what I did there? You've got another letter!)

Any guesses on the name yet? You should have at least one part of it now.

Now that the debugger is working, I'm going to concentrate on the security side of things on the server-side and on getting the site ready for the alpha launch next week.

Update: Mike Davies figured out the domain name... see the comments! :)






Bad Behavior has blocked 0 access attempts in the last 7 days.