How to announce your software product

I ‘m receiving emails announcing new software products daily. But I can ‘t remember even one case when after reading such an email (unless it comes from Google), I ‘d want to try using the product, even for free. For example, this one is from yesterday:

“The XYZ project team is proud to announce the release of version 2.0 of ABC, the next generation XML parser/indexer. LMN version 1.0: the world ‘s first true native XML index that is simple, general-purpose and back-compatible with XML. ” And so on.

I would not even bother blogging about it, but our company is about to release a number cool commercial plugins, and I ‘ll need to write a press release that, most likely people will ignore. BTW,I hate the word cool. “We have just released a cool software that will make your life easier “. “Now the food in our restaurant is even better than before “. Give me a break, will you. The food is either good or bad. Do not offer me the software that will revolutionize my current experience with XML parsers.

Just teach me how to live without the need to write XML configurations to make my software work with yours, give me a real fast internet connection (I mean for real), give me some software that will let me live without worrying about viruses and service denial attacks while maintaining fast Internet connection. This will make me happy and improve my QoL (quality of life).

So when you ‘ll read the announcement about the cool plugins released by our company, just know, that this will be a quality software (typically, quality software engineers write quality software), we ‘ve enjoyed writing it and hope to get a little bit richer by selling it to you. But after purchasing our software, you ‘ll still will have to get up in the morning and go to work. Your life will not change dramatically. If it makes you happy, the last statements apply to us as well – we ‘ll keep going to work.

Most likely your firm will also become a little bit richer because our software will alow your sofware engineers seriously cut time-to-market and improve your users ‘ experience by the factor of 35.6 (Gartner or Forrester will come up with more precise metrics and will be happy to sell you an analytical report for a nominal fee of $54 a page ). Why did I even mentioned these cliches “time-to-market ” and “users ‘ experience “? Excuse my corporate language. Do not know any better.

Would you take a look at the trial version of our software, pleeeeease…

I need to learn from Jeff

I met with Jeff Whatcott from Adobe a couple of times, and have to admit that he ‘s a top-notch professional product manager. He knows how to talk the talk, and I mean it. But let me explain you what I mean. Intelligent Enterprise magazine has published an interview with Jeff on Rich Internet Applications. Of course, Jeff likes Adobe Flex technology for RIA (surprise, surprise).

The question is how do you say it properly? Especially when these journalists are asking questions like what do you think of AJAX, as if they do not understand that you are into Flex and for a good reason. Flex developers really like this product, but I ‘d put them into three categories based on how they ‘d answered the question, “What do you think of AJAX “.

Junior programmers and amateurs would simply say “AJAX sucks “. That ‘s why they are still junior.

Experienced Flex developers would say AJAX sucks because… and they ‘d give a half a dozen of valid reasons (I put myself into this category).

And the top notch professionals like Jeff, would put it right (no irony is intended here). Let ‘s read it, enjoy it, and most importantly learn how to talk the talk.

The journalist asks, “How would you compare Flex with alternative routes to RIAs such as Ajax, JavaScript, Active X and Microsoft ‘s Windows Presentation Foundation? ”

This question is wrong for various reasons. First of all, you can not compare AJAX with Flex as the former is a set of techniques for creation of richer Web applications, while the latter is a product of a particular vendor – Adobe in this case.

Also, asking Adobe product manager what he thinks about AJAX or WPF, is like asking me if I like my wife better that Joe Smith ‘s one.

But Jeff answers the question gracefully. He says, “There are lots of ways to build RIA user experiences, but you have to use the right tool for the job. There ‘s no one tool that ‘s right for every solution. Ajax is really great for bringing incremental improvements to existing Web applications. If you have a big Web app and you want to eliminate page refreshes here and there and bring some improvements to the user experience, it ‘s a great fit because it follows the same [development] model. It ‘s relatively easy for Web application developers to understand and adopt Ajax for simple things, and that takes you pretty far. ”

I ‘d like to emphasize this statement, “If you have a big Web app and you want to eliminate page refreshes here and there and bring some improvements to the user experience, it ‘s a great fit “. Absolutely. AJAX is great tool for improving an old application here and there. Three Botox shots around the mouth. What ‘s that under your left eye? Let me fix it real quick. Ouch!! Done. It ‘s still Joan Rivers, but hey…I do not mind watching her at the Red Carpet this Sunday. Sure, Melissa looks better…a little.

But let ‘s get back to Ajax. Jeff continues, “Ajax gets a lot more complicated and more challenging to use when you ‘re building full-on, large-scale rich Internet applications that are very data intensive and very graphical. A lot of Ajax frameworks are fairly lightweight and not terribly complete “.

Jeff has to be careful, so let me try to interpret this last statement. IMHO, “lightweight and not terribly complete ” means scattered widgets and pieces of functionalities that are not even close to solid Flex framework offerings. Opponents of Flex often say that they do not want to commit to a proprietary technology (they refer to Flex). But they do not get it – since writing AJAX application manually is something that even AJAX proponents do not recommend- you ‘d have to select one of two dozen of immature AJAX frameworks and lock yourself right in this proprietary tool.

And Jeff rightly states so, “Some of the commercial-grade frameworks are more complete, but they ‘re often incompatible and can ‘t be mixed and matched. When you pick one, you are really making a long-term commitment as to how your software is going to be built, so it could be a fairly risky decision. Another problem with Ajax is that productivity tends to suffer because of the cross-browser compatibility issues that pop up when you ‘re dealing with very large-scale applications. It takes time to track down and fix all the bugs. Flex is most powerful in these large-scale, complex development scenarios and it solves all the issues I just mentioned. ”

Since I do not work for Adobe, I have a luxury to say that Flex is not a silver bullet either, you still need to write code and deal with non-trivial tasks daily. But it is a good and extensible platform, which can bring your enterprise Web application to a different level.

The next question was, “What about Microsoft Presentation Foundation? ”

I do not know what Jeff was thinking about their direct competition, but he gave an open answer without burning any bridges, “That ‘s an incredibly powerful tool set. It ‘s really cool stuff and good technology, but it ‘s still a little early. It ‘s not yet widely proven in a lot of rollouts, so there may be lurking issues that we don ‘t know about. ”

This article is a good lesson on interviewing techniques. This does not mean that I will be answering the same way, but I ‘m taking my hat off to Jeff for his speaking skills. I mean it.

Having said all this, I respect people who are overcoming AJAX challenges on a daily basis. I also respect people who climb Everest.

IntelliJIDEA – Java, Ruby…Flex?

JetBrains team is well known and respected in Java community for their excellent IDE called IntelliJIDEA. Java developers in-the-know know – Eclipse is bigger, but IDEA is better. Last year, I had to switch from IDEA to Eclipse, because I ‘ve been doing mixed Java/Flex development, and Eclipse was my only choice.

When JetBrains announced Ruby support in IDEA, it was clear that Ruby fans just won the lottery. The next question in my mind was, “How about supporting Adobe Flex languages – MXML and ActionScript? ” But this was the case when no new was bad news.

Today, I ‘ve got an email with a reference to a ticket opened by Michael Klishin in the IDEA ‘s bug tracking and project management database that asks for Flex support. Way to go, Mike! I ‘m with you.

JetBrains, go for it! Adobe Flex is here to stay, and having two Flex IDEs is better than one.

The top paying jobs in America

CareerBuilder.com has published a list of 50 top paying jobs in the USA. These are nationwide average figures. In New York City, you can easily multiply these salaries by 1.5 to get more realistic numbers. But I still firmly believe that from the return on investment point of view, Computer and Information Scientists is one of the best professions.

Americans, send you kids to CS colleges this year! They can do it!

Rich Internet Applications: State of the Union

We are entering an era of Rich Internet Applications (RIA), and many enterprise development managers are facing the dilemma – which way to go – remain with tried and true Java or .Net technologies or less know yet AJAX, Flex, OpenLaszlo or a number of other vendors. This article is an attempt to give a brief overview of what ‘s out there on the RIA market.

Historically there have been major shifts in the software industry. We moved from mainframes with dumb terminals to client/server. Users gained in convenience and productivity, and mainframe systems were patronizingly labeled as legacy. With the availability of the World Wide Web industry visionaries turned the tables: vendors and corporate IT had been eager to get rid of the complexity of client/server version management and technologists were sold on multi-tier computing. This time client/server was called legacy. Excited with server multi-threading, messaging, persistence, and similar toys, we pretend not to think that, at the end of the day, we ‘d have to trade user experience and productivity for the transparency of application deployment. And to make us feel better, we proudly called the new breed of applications “thin client. ”

Now we are entering an era of RIA, which restores the power of desktop applications…inside downloadable Web page. RIAs run in a virtual machine (i.e., Adobe Flash Player or Java VM) and have the potential of becoming a full-featured desktop application soon. As opposed to just simply displaying Web pages delivered from some server machine, RIA really run on the client. Many of the data manipulation tasks (sorting, grouping, and filtering) are done locally like in the old client/server days. In three or four years most newly developed projects will include RIA technologies.

A rich Internet application combines the benefits of using the Web as a low-cost deployment model with a rich user experience that ‘s at least as good as today ‘s desktop applications. And, since RIAs don ‘t require that the entire page be refreshed to update their data, the response time is much faster and the network load much lower. Think of a globally available client/server application.

Let ‘s illustrate the difference between “legacy ” Web and RIA with a shopping cart example. Non-RIA Web applications are page-based. Since HTTP is a stateless protocol, when the user moves from one page to another, a Web browser doesn ‘t “remember ” the user ‘s actions on the previous page. As a common treatment of this “amnesia, ” a user state is stored on the server side in the form of the HTTP session.

Consider the case of an online shopping session. It can go as follows:

1. The user initiates a search for an item on Web page #1.

2. The server processes this request and returns page #2 that may (or may not) contain the required item.

3. The user adds an item to a shopping cart that takes yet another trip to the server to create the shopping cart and store it on the server side. Then the server responds with page #3 so the user can either continue shopping (repeating the first three steps) or proceed to the checkout – page #4.

At the checkout the server retrieves selected items from the session object and sends page #5 to the user for shipping info. The data entered travels back to the server for storage, and the client gets back page #6 for billing information. After that page #7 will confirm the order and only then goes to the order completion page.

This simplest of online purchases consisted of seven roundtrips to the server. In striking difference to desktop applications, a few-seconds-per-page refresh is considered fast(!) for a typical Web application, and the commonly acceptable delay is up to eight seconds. Is the user motivated enough to complete the purchase? Think again, because your system gave him a chance to reconsider seven times in a row. Now assume that the network and/or server are slow…your potential customer went elsewhere.

Rich Internet applications eliminate the roundtrips and substantially improve system performance by doing a lot more of the processing on the client than a thin client Web application. Besides, RIAs are stateful: they accumulate the information right on the client! To put it simply, RIA isn ‘t a set of pages controlled by the server; they are actual applications running on the client ‘s computer and communicating with servers primarily to process and exchange data.

Both consumer-facing and enterprise applications benefit from being RIAs. It ‘s a well-known fact that e-commerce Web sites such as online ticket reservation systems and online retailers are losing revenues because users abandon shopping carts on non-responsive Web sites during the checkout process. Such Web sites result in lots of calls to the call center, a major operational expense in and of itself. The performance of any system operated by employees is critical to company productivity and RIAs provide a performance boost over HTML applications, while reducing operating and infrastructure costs.

RIA Platforms: The Major Choices

There ‘s more than one way to create RIAs that run in the client ‘s browser with the help of some kind of client engine. These are the most popular products or technologies:

A Java programmer can create Java applets. As mentioned, this solution has been available since 1995.Using Adobe Flex you can create an ActionScript application for the ubiquitous Flash Player, a high-performance multimedia virtual machine that runs bytecode files in the SWF format (pronounced swif). The player ‘s JIT compiler converts the SWF bytecode to native machine code for fast performance. The later facility is specific to Flex 2, available since 2006. Although early versions of Flex were out in 2004, they didn ‘t support just-in-time compilation.Microsoft Windows Presentation Foundation (WPF) was released as part of .NET 3.0 in November of 2006 and can be used to create both Internet and desktop applications (it also has the Everywhere version – WPF/E).AJAX, a k a DHTML, born circa 1998. This solution was recently boosted with XMLHttpRequest API support for all major browsers. AJAX served as a wake-up call for the user and developer communities. It is often the first step on the migration path from the legacy Web to the world of RIA despite being seriously handicapped by having to support browser incompatibilities and a poor programming model.Java

Even though the Java programming language became popular largely because of applets and the famous dancing Duke (http://java.com/en/download/help/testvm.xml ), applets haven ‘t become Java ‘s main use pattern. The main reason: the large footprint of the required JVM (currently 16MB). And there are other drawbacks. For instance, although Java Swing pushed a platform-independent look-and-feel, absent any good-looking off-the-shelf GUI widgets it was hard selling it to the public. In this regard Flash and Flex creators did a much better job with their eye-candy components. Or take audio and video integration. Today people are used to having streaming audio and video components embedded in Web pages. But the multimedia Java API remains rudimentary, to say the least.

There are some efforts to minimize the size of the JVM used by Web browsers and the Java Browser Edition project now needs “only ” about 3MB to run a primitive Hello World applet. But this can ‘t compete with Flash Player 9, which managed to accommodate two virtual machines in a 1.2MB download that can run any RIA however complex.

Another issue with Java applets is that they don ‘t offer a seamless download of the proper version of the JVM along with the applet. Flash Player ‘s express install does precisely that.

Having said that, I must acknowledge that Java Swing is a very mature and robust technology for creating GUI applications delivered either over the Web or installed on the desktop. You can do literally anything with Java Swing – if you can afford it. No, you don ‘t pay licensing fees, but because of the longer development cycle and need to engage expert programmers, industrial-size Swing projects are usually quite expensive to build and maintain.

Adobe Flex 2

Flex 2 applications run cross-platform in a ubiquitous Flash Player 9 that ‘s a lightweight virtual machine. The platform includes:

an XML-based language called MXML that supports the declarative programming of GUI components targeting designers; the standard object-oriented programming language, ActionScript 3.0, based on the latest ECMAScript specification; server-side integration via Flex Data Services giving client applications transparent access to the world of J2EE;charting components, access to multimedia controls, etc;and an Eclipse-based full-featured IDE with automated deployment, debugging, and tracing facilities.The Flex 2 platform is easily extendable and integrates well with server-side Java, ColdFusion, PHP, Ruby, ASP, and the like.

The SWF file format is open, and there are third-party open source products that offer tools for creating RIAs delivered by Flash Player like OpenLaszlo from Laszlo Systems.

This is what comes at no cost with Flex 2:

MXML – an XML-based declarative programming language for creating GUI.ActionScript 3.0 – an object-oriented language similar to Java. Flash Player 9 – a virtual machine with a tiny footprint that lives inside a Web browser and runs your compiled bytecode (.SWF). Command-line compilers and debugger.Flex Framework, which includes a library of well-designed GUI component: buttons, tab folders, data grids, tree controls, animated effects, and more. Flex Data Services Express (FDS) – a template Web application deployed in a J2EE server to communicate with ActionScript client application run by Flash Player. FDS Express is limited to a single CPU, which makes it useful only for learning purposes.The following Flex tools require a purchased license:

Flex Builder – the Eclipse-based IDE Charting component Flex Data Services Departmental, 24×7, 100 concurrent users Flex Data Services Enterprise, 24×7, unlimited usersIn a nutshell, the process of creating a basic Flex 2 application consists of the following steps:

1. Design application by adding MXML components like this button:

lt;mx:Button label= “Place Order ” click= “processOrder(event) “/ gt;

If you use Flex Builder IDE, you can apply drag-and-drop techniques. Alternatively, you can write the MXML as text.

2. Write the code in ActionScript per your functional specification, for example:

private function processOrder (event:Event):void{

//The business logic goes here

}

3. Compile the code: The Flex compiler automatically converts MXML into ActionScript and creates bytecode output in a form of an SWF file to be run in Flash Player 9 or above. You ‘ll enjoy a fully automatic compilation process if you use the Flex Builder IDE.

4. Deploy the SWF file and the wrapping HTML page in the Web server of your choice. The deployment process and creating the wrapped can be completely transparent if you use the Flex Builder IDE.

More advanced Flex applications can include interaction with the server-side systems through FDS, which provides remote access to server-side Java objects and Java EE components, extensive messaging support (including JMS integration), synchronization with persisted data, and integration with other persistent technologies. WPF

Recently released Microsoft ‘s Windows Foundation Platform, or WPF uses an XML-based declarative programming language called XAML to create GUIs and C# as a general-purpose programming language. WPF is suitable for creating both RIA and desktop applications. XBAP stands for XAML Browser Application and it ‘s a WPF way of creating RIAs that runs in Internet Explorer.

Microsoft has released a Beta version called WPF/E that will run on some non-Windows platforms (this version uses substitutes C# with JavaScript). While living in a sandbox, XBAP will have access to all .NET 3.0 functionality but WPF/E won ‘t. Common Language Runtime (CLR) is the client ‘s WPF engine.

To create WPF applications, developers can use Microsoft ‘s Visual Studio 2005 IDE with installed .NET 3.0 extensions. The next version of this IDE, called Orcas, will include a visual GUI designer. WPF developers use the same code base for writing XBAP and desktop applications: they just enclose the code sections that aren ‘t allowed in XBAP into the ifdef blocks.

Microsoft XAML code looks similar to Adobe ‘s MXML. Even though today ‘s Flex 2 is a lot more mature than WPF, Microsoft has an established developer base, while Adobe traditionally catered to designers, and its main goal today is to convince enterprise developers (particularly the Java camp) that Flex can be a tool of choice for creating business RIAs.

AJAX

While the term AJAX was coined by Jesse James Garret in February of 2005 and is partly rooted in the asynchronous XmlHttpRequest implemented by Mozilla, lots of developers have used Microsoft ‘s version of XMLHttpRequest and alternative techniques like IFrame since 1999. These techniques facilitate synchronous and asynchronous communications between the script in a page and server-side code. The main problem with AJAX is that despite its popularity it has no technical foundation. While the other solutions we mention here are based on rock-solid virtual machines, there ‘s no standard VM for AJAX. Each browser implements AJAX building blocks differently. There ‘s a chance that deployed AJAX application will require code changes with each new browser release. Wait, let ‘s rephrase that: there ‘s a chance that a deployed AJAX apps may run as is on a new browser release. Do you want to take chances with your business?

That said, Internet giants like Google, Yahoo, and Amazon are building AJAX apps on top of their own abstraction layers such as Google Web Toolkit (GWT). Because of the immature level of the technology, these abstract layers need constant vendor attention as soon as changes appear.

AJAX Shortcomings

An ability to create flicker-free Web apps without buying more software is AJAX ‘s big appeal. You may have heard the chant “AJAX is free. ” Here ‘s the simple translation: no commercial AJAX tool is worth paying for. There are hundreds of libraries, toolkits, and control sets that give you the impression that AJAX applications are cheap to develop and strategically safe since there ‘s no vendor lock-in. Actually, there is vendor locking because you won ‘t manually write JavaScript code and will have to pick an AJAX library of some vendor. Now think about it: starting from the ground up you need a communication layer, messaging and remoting mechanisms, an HTTP sniffer, a library of UI components with shared objects and event models, a visual IDE that understands these components in design time, and a debugger that accommodates all this stuff. On top of that, there ‘s internationalization support, accessibility for the disabled, and support for automated testing tools.

You really think you ‘re safe with mix-and-match from different vendors? If the answer is yes, you must be working for a software company in the RIA business. Coming to reality, long development cycle, lack of free quality GUI components, and the shortcomings listed below make AJAX less appealing and, actually, the most expensive way of creating RIAs.

These are some of AJAX ‘s current drawbacks:

JavaScript development tools are limited due to the dynamic nature of the language, and debugging any DHTML/JavaScript mix is a pain. Yes, Google ‘s GWT can spare you from writing JavaScript manually, but at the end of the day, it ‘s still JavaScript that has to be deployed in production. When the system isn ‘t working and time is limited, what are you going to use to debug it – the real page of Java mock-up?

Tons of JavaScript source code has to go over the wire to the client to be interpreted by the browser. We ‘re talking about business applications, not some proof-of-concept demo.

Web browsers will happily display your application even if a piece of JavaScript didn ‘t arrive at the client. You won ‘t know of a problem exists until you execute the particular use case.

A simple right-click followed by the “View Source code ” menu option would reveal your business application code. Better yet, all this code resides as plain text in the browser cache on disk. Because of this, you have to drop all the code comments and use obfuscators to protect your code from being stolen.

HTML rendering is slow: think of a data grid that contains 5,000 records. How long are you ready to wait for your sales report?

Any data manipulation by JavaScript is inherently slow because JavaScript is an interpreted, not a compiled language. We ‘re talking thousand of times slow.

The code is more vulnerable to hacker attack, a fact that was proved recently by a worm that stole a bunch of mail addresses from Yahoo address books.

AJAX doesn ‘t support server push. The server-side application can ‘t publish the data directly to the client. AJAX applications have to poll the data from the server at specified time intervals without knowing if the data is there or not.

It ‘s not easy to find good AJAX programmers.

To summarize, if you ‘re developing a new enterprise business RIA from scratch, AJAX may not be the way to go. Choose a solid application development environment that offers a virtual machine at runtime like Flex/Flash, Java, or WPF. Any of these environments is more productive than AJAX. If you already have AJAX applications you can nicely integrate new Flex RIAs in existing AJAX applications using tools like FABridge from Adobe for communicating between AJAX and Flex.

During AJAX ‘s first year of life, every article or book on the subject mentioned Google Maps and Gmail, and various type-ahead samples: you enter the first zip code digit in a text field, and it suggests your possible choices based on your input without a page refresh. Today, you can read about a number of AJAX applications, including ones that work with photo images loaded from the popular flickr.com Web site.

Lastly, I ‘d like to make it clear that popular comparisons of Flex versus AJAX are simply wrong, since Flex is a framework and complete development platform, while AJAX is a set of techniques. To compare apples to apples, you should compare products like Flex against GWT (Google) and the like.

Other RIA Solutions

OpenLaszlo

OpenLaszlo from Laszlo Systems is an open source product that lets you create applications that can be deployed as DHTML or Flash Player files. The ability to generate DHTML code made it a good candidate for developing applications for mobile devices, and Sun Microsystems has recently partnered with Laszlo Systems to bring this technology to the Java mobile space. This is direct competition for Adobe Flash Lite.

GWT

GWT stands for Google Web Toolkit lets you write programs in Java and convert them to JavaScript so they can be delivered as AJAX Web applications.

An interesting GWT feature is that it compiles Java into various versions of JavaScript to accommodate the specific needs of different Web browsers. GWT comes with a library of extensible components. The number of these components was limited, but that will probably change soon, because it ‘s Google.

NexaWeb

NexaWeb offers a Java-based thin client that doesn ‘t require any additional installation on the user ‘s desktop. The application ‘s state is controlled by a small Java applet running on the client. This applet communicates with the NexaWeb Java EE application as needed. To avoid issues related to the version of the Java Runtime Environment installed with the Web browser, NexaWeb uses JRE 1.1 for its applet.

Some Pragmatic Flex/Java Considerations

Cool technologies come and go. Only some of them settle down in the toolbox of a professional programmer working on enterprise business applications. The technical excellence of any software is important, but it ‘s not the only component in its success.

The Learning Curve: Reuse of Skills and Code

One important concern of any development manager is the availability of a large pool of people who know a particular software. There are plenty of Java programmers with the skills required to develop Web applications, and the good news is that enterprise Java developers with servlet/Java EE programming skills or Java Swing experience will find the Flex path very easy.

Java and ActionScript 3 are very similar; Eclipse is a familiar environment for many Java developers. Since Flex piggybacks on Java EE and browser technologies, a server-side Java programmer should be able to correlate his current skills with the development process in Flex. Java Swing developers will instantly spot similarities to Java event and layout models. In our experience, the typical ramp-up time for motivated Java developer is two weeks. The best part is that Flex seamlessly integrates with existing Java server code of any flavor – POJO, EJB, Hibernate/Spring, or JMS, so the server-side part can literally remain unchanged.

Application Security

Another important consideration is the security of Flex/Java applications. Flex server-side security management is quite extensive, and it lets you use either container offerings or custom security providers via declarative XML binding. There are a couple of challenges since Flex supports multiple protocols, so Java EE security that relies only on HTTP sessions has to be extended, but it ‘s a simple and well-documented process. On the client side, it builds on Flash Player security that ‘s known for its lack of serious security flaws. You have a built-in security manager that has all the standard protection for cross-domain and zone access. Corporations can further restrict the code they get from third parties by wrapping the code loaders in additional security managers.

Flex GUI Performance

Java Swing is a tried and true tool for developing responsive GUIs in demanding applications like stock trading and online auctions. Flex is capable of providing near-real-time data rendering to the GUI and very high refresh rates on large data sets. Flash Player 9 is the high-performance modern virtual machine with precompiled optimized code and a just-in-time (JIT) machine code compiler.

Shorter Development Cycle

It ‘s very possible to build the client side of a real-time portfolio display integrated with news feeds and graphs in about 200 lines of Flex 2 code. A similar Swing program (even if it ‘s created with commercial IDEs) would be several times larger.

A decent Flex developer should be able to prototype (short of server processing) most of the UI for a specific trading system by the end of the first week. If you ‘re lucky and system integration went okay, you can add the collaboration features and multimedia – with the total client code base for the whole project coming within 1,000-1,500 lines. This is definitely not possible with Swing. Of course, some people will say modern Java IDEs generate lots of boilerplate code automatically, but this is still the code that someone has to read, understand, and fix if needs be.

Having said all this, there is a big difference between an application prototyping and delivering a final product – you still need to write code, create new components extend ActionScript classes and implement interfaces. Flex is not a magic wand.

Flex: Room for Improvement

While many programmers who dealt with previous versions of Flex are really happy now that they have a professional Eclipse-based IDE, Java programmers are spoiled by the variety of excellent and responsive IDEs. Flex Builder helps a lot in writing Flex code, but it ‘s not as Flex Builder helps a lot in writing Flex code, but it ‘s not as sofisticated and elegant as it could have been. It ‘s even not as good as its daddy Eclipse.

While you can use Flex just to connect to your existing applications written as JSP or any other HTTP-compatible technologies, you ‘ll get performance gain if you ‘ll use Flex remoting and messaging that is build on fast Adobe proprietary protocols called AMF3 and Real Time Messaging Protocol (RTMP). To take advantage of these benefits you have to purchase Flex Data Services licenses, while may not be affordable for small businesses.

Connection Management

Flex provides an extensive infrastructure for managing connections between the Web browser and the server. It lets you specify all the protocol details for the RTMP, HTTP, HTTPS as well as plain socket connections. You can then specify the order in which the protocols should be tried due to availability/firewall issues. You also get alternative real-time push or pull connections on additional protocols, a direct socket API, and tons of low-level hooks that let you build any protocol you want.

Flex and Agile Development

In mid- lsquo;90s PowerBuilder and Visual Basic were the tools of choice in the client/server field. Software developers didn ‘t really worry about what was under the hood, but more importantly, they were business users ‘ best friends. They could do stuff quickly, or using the modern jargon, they were agile programmers without even knowing it. They ‘d ask the business user Joe, “How do you usually do your business? What would you like to have on this screen? Describe the steps of your business process. ” Most likely Joe wouldn ‘t know all the answers, but this was okay, because developers could come back to the user the next day with a working prototype. This was easy with PowerBuilder ‘s DataWindow. When Joe-the-user saw the prototype, his glassy look all of a sudden would become friendly and understanding. Now Joe was back in control: “No, you did this part wrong, I wanted it different. ” No problem, developers would return with the changes the next day (not next month, but the next day!).

Developers didn ‘t really know how DataWindow worked, but they trusted this component. PowerBuilder used event-driven programming model, which was clean and simple. Object A triggers event XYZ on object B, and this event can carry a payload – the data that object B needs to operate. Using modern jargon it ‘s called Inversion of Control or Dependency Injection design pattern. What ‘s important is that the object B doesn ‘t know about object A. On the same note, if object B needs to return the result of some internal function back, it would broadcast this result “to whom it may concern ” by triggering one of its own events. This is loose coupling in action.

The mentality of many Java programmers was different. They ‘d assign lower priority to the user ‘s windows and spend most of their time designing a multi-tier system that didn ‘t depend on any specific look-and-feel and could be universal. Meetings with Joe would be rare because they couldn ‘t create a decent prototype fast. Fancy IDEs with GUI designers like Matisse weren ‘t in the picture yet and, more importantly, Java programmers were thinking big: UML, design patterns, application servers, and clustering. They enjoyed the programming process for itself. They didn ‘t like the mindset of old-fashioned PowerBuilder or Visual Basic programmers who were thinking windows and screens.

With Flex you started to care about the business users again. You can change the prototype twice a day, and Joe can do the same with his business requirements. No pile of project documentation is needed. The napkin is back and it works. Flex architects can give the server-side Java team the final okay only after Joe is 100% happy.

Besides, with Flex we can have the best of both worlds: the source code of the Flex framework is available, we can learn how it works inside, and override some functionality with what suits our needs better.

Working with Flex promotes agile development, where the people we build the software for are the driving force. Agile development methodology suggests minimizing each development cycle to mitigate the risk of delivering something to the users that they don ‘t want. Agile development encourages frequent face-to-face meetings with the end users as opposed to preparing and sending documents back and forth.

Summary

This quick overview of major RIA-enabling technologies and various approaches to making Web applications richer. It ‘s by no means a complete list: new commercial and open source RIA frameworks and components arise every day. Regardless of what RIA tools you are going to select, start your evaluations now to get a competitive edge.

Namespaces in Flex and Soprano

In XML, namespaces are used to avoid potential naming conflicts with other components having the same names. Since Flex lets you program in MXML and in ActionScript 3, I “ll go over the syntax of namespaces in both of them. Familiarity with Soprano family is a pre-requisite for reading this article.

Namespaces in MXML

MXML applications start with the lt;mx:Application gt; tag that includes xmlns property:

lt;mx:Application xmlns:mx= rdquo;http://www.adobe.com/2006/mxml rdquo; layout= “absolute ” gt;

The namespace mx:xmlns refers to the URI http://www.adobe.com/2006/mxml that lists valid MXML tags. Open the file flex-config.xml, and you “ll find there an XML element that links this URI to the file mxml-manifest.mxl, which list all MXML components. Here “s an extract from this manifest file:

lt;component id= “ButtonBar ” class= “mx.controls.ButtonBar “/ gt;

lt;component id= “Canvas ” class= “mx.containers.Canvas “/ gt;

lt;component id= “CheckBox ” class= “mx.controls.CheckBox “/ gt;

lt;component id= “ColorPicker ” class= “mx.controls.ColorPicker “/ gt;

lt;component id= “ComboBox ” class= “mx.controls.ComboBox “/ gt;

If you want to use one of the standard MXML components, specify the prefix mx for each of them. For example, to use MXML Label, you write the following:

lt;mx:Label x= “111 ” y= “81 ” text= “Hello World “/ gt;

If you are going to create custom Flex components, keep them in a separate namespace to avoid naming conflicts. For example, if you are going to develop a custom Tree component, introduce another namespace, for example with the URI com.enron.controls.* as shown below:

lt;mx:Application xmlns:mx= “http://www.adobe.com/2006/mxml

xmlns:lib= “com.enron.controls.* ” gt;

hellip;

lt;lib:Tree id= “tree ” width= “50% ” height= “100% ” hellip; gt;

lt;/lib:Tree gt;

lt;/mx:Application gt;

This sample defines two namespaces: mx and lib. The lt;lib:Tree gt; notation means that we are planning to use a Tree component from the namespace that we called lib. As you can guess, I assume that you are going to program this Tree component in the ActionScript “s package com.enron.controls and will have to provide either the code of our Tree component or the SWC library that includes this Tree.

The namespace URI tells Flex where to look for the file implementing this component. You can either create a subdirectory com/enron/controls in the application “s directory, or preferably keep it in a separate location that is included in the classpath of your application (read about flex-config.xml file and the source-path tag in Flex documentation). Since we “ve defined two namespaces here, we can use components available in any of them.

You can also specify so-called local namespace using notations like xmlns= rdquo;* rdquo; or xmlns:mylocal= rdquo;* rdquo;, which tells Flex to look for components that are located in the same directory as MXML file or, in case of Flex Data Services, in the /WEB-INF/flex/user-classes directory.

Namespaces in ActionScript 3

Namespaces in ActionScript 3 as well as in MXML are used to control/limit the scope (visibility) of the methods, properties or constants. They are also used to avoid naming conflicts in cases if you create your own custom components that may have the same names as the Flex Framework or other vendor “s counterparts.

You can think of access control keywords public, private, protected and internal as a built-in name spaces. If a method has been declared as

protected calculateTax(){}

you can say that the method calculateTax() has a protected namespace. But AS3 allows you to define your own namespaces to be used instead of these standards language qualifiers.

To introduce your own namespace, you need to perform the following steps:

– Declare a namespace

– Apply the namespace

– Reference the namespace

Let “s write a simple program for an accountant who calculates taxes, but customers that belong to mafia should pay only half of the amount. To do this, we “ll start with declaring two namespaces called regular and soprano. This is the content of the file soprano.as

package com.enron.namespaces {

public namespace soprano= “http://www.enron.com/namespaces “;

}

Please note that the use of a URI in the namespace declaration is optional. The listing below does not use any explicit URI, but the compiler will generate one. This is how the namespace called regular may look like (it ” defined in the ActionScript file regular.as):

package com.enron.namespaces {

public namespace regular;

}

To apply the namespaces, we “ll define a class Tax with two methods calcTax() that will differ by the namespace access attribute and by the amount of “calculated rdquo; tax. The ActionScript class Tax may look like this:

package com.enron.tax{

import com.enron.namespaces.*;

public class Tax

{

regular static function calcTax():Number{

return 3500;

}

soprano static function calcTax():Number{

return 1750;

}

}

}

The testing class TextTax looks like this:

package com.enron.test

{

import com.enron.namespaces.*;

import com.enron.tax.Tax;

import mx.controls.Alert;

use namespace regular;

// use namespace soprano;

public class TestTax

{

public static function myTax():void {

var tax:Number;

tax=Tax.calcTax();

Alert.show( “Your tax is “+ tax, “Calculation complete “);

}

}

}

Since we apply the namespace for the regular customer, s/he will have to pay the tax amount of $3500. The MXML code that uses TestTax is shown below.

lt;?xml version= “1.0 ” encoding= “utf-8 “? gt;

lt;mx:Application xmlns:mx= “http://www.adobe.com/2006/mxml

layout= “absolute ” creationComplete= “initApp(); ” gt;

lt;mx:Script gt;

lt;![CDATA[

import com.enron.test.TestTax;

public function initApp():void {

TestTax.myTax();

}

]] gt;

lt;/mx:Script gt;

lt;/mx:Application gt;

The output of this program looks as in a screenshot below.

Switch to another namespace by changing the use statement to look like

use namespace soprano;

and the amount of tax to pay will by substantially lower. Besides the directive use that affects the entire block of code, AS3 allows more fine grained notation to refer to a specific namespace with a name qualifier (a double colon). In our example, this may look like this:

tax = Tax.soprano::calcTax();

This is the output of the TextTax.mxml for regular customers. For obvious reasons I do not show the output of this program for Soprano family members.

Using namespaces provides additional means of the visibility control (especially if you have something to hide). The methods, class properties of the constants can be physically located in different packages, but marked with the same namespace qualifier, and a one-line namespace change can engage a completely different set of methods/properties across the entire application.

Well manners for boys

This Saturday I took my son to the class called “Well manners for boys ” – it took place in the local community college. I was sitting in the lobby waiting for this class to complete. The security guard, a retired police officer put it simple, “When I grew up, we did not study well manners. Our parents would kick us in the ass, and this was it. Left hook was the manners. Or a nun would twist your ear. It was better back then. ” I guess, the very fact that this class was scheduled was so unusual, the a pretty large newspaper Asbury Park Press has sent a journalist to write about this class. She asked me, “Why did you bring your son here? ” I told her that I ‘m here because American public schools do not teach it, and it ‘s a shame. I did not tell her that I hate the fact that kids here truly believe that sneakers is the the right footwear for all ocasions. I did not tell her that I hate to see ladies in expensive fur coats wearing sneakers (they ‘ve never attended the “Well manners for girls ” class). I did not tell her about stupit habbits of wearing baseball hats all year around, inside and outside the house. I did not tell her that when you bring your son to a fine restaurant he should not order a hamburger, french fries and coca-cola. I did not tell her that using a knife while eating is a must…

Take a look at the program of your local community college. You may be surprised by the variety of the classes offered. And they are cheap two. Six Yoga classes $89. Manners cost only $29 – can ‘t go wrong with this. This lady came for an Aroma Therapy lecture. And these people are here for the class called “eBay simplified “.

I ‘ve been watching people coming in and signing up for classes, and the most popular class in this college today was “How to become debt free “. The cop was greeting each person with the words, “So you want to be debt free, aha! “. Most of the students of this class were middle age women. Why are they here? Is this because of their husbands who wasted all family money? I wonder if people attending the eBay class will come back next year studying how to become debt free?

When my son came out of the class, I ‘ve asked him, “Tell me something that you ‘ve learned “. He slowly said, “Hello, My name is David. It ‘s nice to meet you “. He made a good eye contact and shook my hand exactly three times.

Then I asked him, “What part of the lesson was the most fun? ”

– “Leaving “.

Gorby begs Gates

Michail Gorbachev asks Bill Gates to help a modest school teacher from Russia in the accusation of the pirate use of MS Windows in school. In the unlikely event if you can ‘t read Russian, just take the text of this open letter to Bill Gates from Gorby ‘s fund, open Google Translate and read (Russian to English is still in beta, but you ‘ll get the point)

“Dear Mr. Gates, We greatly respect the labor of Microsoft programmers. Please do not send this teacher to Siberian prison camps. He ‘s purchased computers to the school where he ‘s teaching with pre-installed pirate Windows OS and now he ‘s facing … ”

Russia is one of the most rotten and corrupt countries in the world. Criminals are running this country, and now they found this poor teacher and want to send him to jail. This country is fucked up, big time. What a hypocrites!

This is the Reuters story and one more .

Overpaid? Hardly.

This is a sequel to the blog called “Underpaid? Quit! “. Information Week magazine has published an article Is Exec Pay Excessive? The author answers, “Hardly “. I agree with him. Market always works correctly. If you are wondering why a policeman earns $50K annual salary while risking his life, the author explains, “…it just means that employers can find more of them at the pay they now earn “. Do you think it ‘s fair that a 20 year old basketball player (whose vocab is “Yo, man ” and 500 more words) earns 10 times more that the president of the USA? I think it ‘s fair because thousands of people are willing to pay big bucks for a game ticket when this Yo, Man is playing. He earns his salary. Big time! Do you think that his agent is overpaid? Hardly. Without his agent this superstar would still be playing in his neighborhood playground on weekends.

Or take Maria Sharapova. Does she earn her pay check? Absolutely! She ‘s pretty (by today ‘s norms) and technically she does not even need to play tennis. Maria can just wear these sexy Nike outfits, walk around the tennis court and scream once in a while. Trust me, men will keep purchasing tickets.

Do you think that your IT boss earns too much? I do not think so. Do you think that without you your project would fail? Do not think so. Why your boss is getting paid a lot more without knowing Java or C++? You boss has much more responsibilities than you do. Your boss is responsible for all mistakes you make. Your boss has a Blackberry, and only stupid people can think that this is a privilege. Your boss is on a leash 24×7. Ask yourself, do you think it ‘s going to be better if you ‘ll get a new boss? Still do not like your boss? Quit, and see if the new one will be better.

Do you think that they pay you too much? Hardly. You worth every penny you make today! And tomorrow.

Who are the heroes of i-Technology – my version

Jeremy Geelan has published his list of 100 all-time heroes of i-Techlogies. I ‘d go with a shorter list and removed the “All-Time ” from the title. The “All-Time ” is not applicable for IT personalities. A hundreds years from now people will laugh like crazy reading most of the today ‘s blogs and books on programming. But it ‘s a thought-provoking list and you are encouraged to come up with your own list.

This is the list of IT personalities I respect (in case if this blog will live forever, this is the version of February 4, 2007 9AM EST). These are people of different caliber, but I do respect them a lot.

1. Bill Gates – this guy is above and beyond. While the blogoshpere is heavily infected with Windows-bashing blogs, most of these these hypocrites are using Windows daily. Bill is a perfect combination of a technical savvy guy and a businessman.

2. Donald Knuth – the author of the multi-volume The Art of Computer Programming, one of the most highly respected references in the computer science field, which is not known to 90% of the current professional programmers.

3. Sergey Brin – Google CEO. This company makes a difference. I do not know how he did it, because I ‘m sure that there were/are other comparable search engines. It ‘s not about search engine, it ‘s about Google.

4. Joel Spolsky – a smart guy and one of the best essay writers in IT.

5. Dennis Ritchie – creator of the C language.

6. Joe Celko – an SQL guru and writer. If you do not know him (and SQL), it ‘s a shame.

7. Tim O ‘Reilly – the IT book publisher. There are many of those, but somehow O ‘Reilly ‘s books stand out.

8. James Gosling – creator of the Java language. Many people can create a programming language, but not many people can create and market (Sun Microsystems deserves lots of credits here) a programming language that is used by five million people in the world.

9. Steve Jobs – a man with a vision from Apple. There is always something cooking in Apple ‘s kitchen. I wonder what ‘s coming after iPhone?

10. Jeff Bezos – a founder of the first super-successful Internet Enterprise – Amazon.com. Do you still think that Amazon is an Internet book retailer? Big mistake. Huge. Think Web Services, storage and virtual servers solutions, mechanical turk…

11. Yakov Fain – there is no entry for my name in Wikipedia yet, but my wife firmly believes that I am a very good programmer who is underpaid and should bring more money home. Even though she ‘s a programmer herself, she does not read my blogs, otherwise she ‘d know my opinion on “underpaid programmers “. But anyway, I respect this opinion and hopefully one day some large firm will recognize it too, and will start using my potential to its fullest.