Saturday, October 13, 2007

Can a Flex application support 500,000 users?

Well, at betfair.com we're going to find out pretty soon as we're pretty close to launching the next generation exchange games trading platform to over 1 million registered customers. If you're attending MAX Barcelona check out Manny Correia's presentation on Tuesday 16th October at 16:00 where you'll get a chance to see a demo of this application.

If you're based in the US make sure you don't miss this session as this may be your only chance. The recent (somewhat misleadingly named) US Port Security Act prevents non-US based gambling companies, including betfair.com, from trading in the US. This act is so at odds with the existing free trade agreements that even the World Trade Organization has ruled against the US. In other cases similar WTO rulings have resulted in severe economic sanctions against the offending country.

Monday, August 20, 2007

Colin Moock's guide to Flash for Flex programmers

One of the things that makes me laugh (and cry) about the Flex 2 documentation is that it implicitly assumes that the reader is familiar with Flash. Given that Flex is supposed to be a development environment targeted at traditional developers (familiar with Eclipse and source code control and the like), you'd think that it would be a fair assumption that at least a significant share of the readers of the Flex 2 doc set would be Java, C++ or C# programmers (like me) who are keen to understand how to build rich clients in Flex.

I guess that other newcomers to Flash will probably have the same frustrating time as I did trying to figure out how (and when) the AVM2 dispatches mouse, focus and keyboard events, how to refer to the instance's properties of a symbol created with
Flash CS3 using the Flex Component Kit for Flash CS3, and how to write programmatic skins etc...

So I thought a guide to Flash for Flex programmers was needed and I even though about writing one. That is until I read Colin Moock's recently published Essential AS3 book. Section 2 is
the essential "missing manual" on the AVM for Flex developers who don't come from a Flash background and Chapter 29 is the perfect introduction to the Flash IDE for Flex programmers.

One day there might be a book on the Flex class library of the same thoroughness and quality.

Sunday, August 05, 2007

Flex's DateTimeAxis renders in GMT by default!

I have to admit to that fact that getting used to Flash's Date class has been a struggle, especially in its new localized form. If you instantiate a Date with a single parameter, it assumes the parameter you supply is the number of milliseconds since UNIX was cool, and it also assumes you're specifying the time in GMT. All is fine. If, however, you instantiate a Date with several parameters, (specifying the day, month and tear etc... separately) it assumes that you're specifying the date in "clock-on-the-wall" time. Once you've created the Date object, its toString() method renders the time in "clock-on -the-wall" time.

The fun really starts when you render a collection of Date objects using Flex Charting. Despite the fact that the Date class's toString() method renders UTC times in "clock-on-the-wall" format by default, the mx.charts.DateTimeAxis class renders Date objects in a line series in UTC by default.
Thankfully the DateTimeAxis class has a property called displayLocalTime that you can set to "true" to get the Date objects rendered in "clock-on-the-wall" format but it's not the default.

Thursday, August 02, 2007

Flex jobs at betfair.com in London, England

I recently joined betfair.com as the development lead for a new team responsible for reimplementing the gaming systems in Adobe Flex. We've already completed a beta and, because of the positive feedback, we now need to urgently grow the development team in London, England.

We're looking for talented developers who have experience of developing service-oriented smart clients in a team environment, ideally with
first-hand experience of Adobe Flex2 and Cairngorm but strong candidates with experience of Java Swing and/or Windows Forms.NET will also be considered.

Launched in 2000, betfair.com is the world's leading online betting exchange
with customers more than 35 countries. betfair.com provides a similar service for online betting that a "derivatives exchange" offers for the financial markets, just at a much bigger scale (over 1 billion trades were processed on the exchange last year). betfair.com is a profitable company with annual revenues exceeding GBP 140 million (USD 280m).

If you're interested in applying for one of these positions please send your resume to me at graeme dot harker at betfair dot com.

Wednesday, June 27, 2007

Happy Brithday Flex 2

By my calculation it's exactly one year ago today that Flex 2 went GA. Happy birthday! A lot's changed in a year.

Thursday, May 31, 2007

Does Flex need an fconsole (like Java's jconsole)?

As Flex is used for more complex applications and is more widely used in the enterprise I'm wondering how long it's going to be before people want to peer inside the black box of the Flash Player and see how it's working (how the garbage collector's working, how many event/s it's processing and how it's using the operating system's vm system).

Java's addressed this with its JMX framework and the super-cool free jconsole tool that comes with the JDK that charts thread and memory utilization.

Grant Skinner
's been writing some cool stuff
on the Player's memory management system. This presentation is a must for anyone developing enterprise Flex applications).

How long it will be before people will be asking if Flash Player needs an fconsole?

Thursday, April 05, 2007

Did Mark get the idea for Flex from his parrot?

In a interview with Mark Anders in today's UK Guardian newspaper, Mark talks about ASP.NET, Flash as a development framework and his parrots!

Sunday, March 04, 2007

The Flex compiler doesn't spot name conflicts

Beware! The Flex 2.0.1 compiler appears not to notice the reuse of the same identifier if decalred as both static and non-static in (what in any other language would be) the same namespace. The equivalent throws a hard compile-time error in both .NET 3.0 and in J2SE 5. The following example compiles without error. Is this a bug or is it supposed to be like this in AS3?

Saturday, March 03, 2007

Is Flex's valueCommit dispatched at the right time?

The more I work with validators, the more concerned I am about whether TextInput's valueCommit event is raised at the right time. You could imagine a scenario where a TextInput's text property is only committed when the user is happy with the input and moves focus to another component, at which point the valueCommit event is dispatched. Unfortunately that's not how the TextInput component works. In fact, the TextInput component updates it's text property (and anything bound to its text property) after each key depression. Hence its actually "committing" its "value" after each key depression (when the change event is dispatched). This makes no sense to me at all. Either the valueCommit event is badly named or its dispatched at the wrong time in the live cycle of this component. Thoughts?

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" backgroundColor="white" backgroundImage="">
<mx:Script>
<![CDATA[
private function onChange() : void
{
trace( this.textInput.text ) ;
}

private function onValueCommit() : void
{
trace( "onValueCommit()" ) ;
}
]]>
</mx:Script>
<mx:Label text="{this.textInput.text}" />
<mx:TextInput id="textInput" change="this.onChange()" valueCommit="this.onValueCommit()" />
<mx:TextInput />
</mx:Application>