Space of Flex/AIR technologies

Beyond Plain Old Html Objects

Archive for the ‘Articles’ Category

AMF Playground with public services, Flash/Flex client-server communication

without comments

Today I published a microsite (http://amf.riaspace.com/) on my blog dedicated to AMF communication. The goal of it is to gather necessary information needed for quick start with AMF.

You will find there:

  • Publicly available AMF services for the start without setting up your own server environment
  • Code snippets demonstrating how to utilize AMF services
  • Video tutorials on how to setup your own Flex/Zend_Amf projects
  • Demo applications with a source code

At the moment I’m hosting only PHP based services but I’m also thinking about Java based backend to be able to play with messaging.

Written by Piotr Walczyszyn

July 15th, 2010 at 9:58 am

Posted in Articles,Releases

Tagged with , ,

Configuring Eclipse PDT and Flash Builder 4 Plug-in for PHP/Flex development

with 5 comments

In this tutorial I will explain how to configure a development environment to work with PHP and Flex projects in one tool. In order to do that I will use Eclipse PDT 2.1 (PHP Eclipse plugin), Flash Builder 4 Plug-in Beta 2 and the latest Eclipse IDE for Java EE Developers package, which is eclipse-jee-galileo-SR1-macosx-carbon (of course if you are on Windows you should get the proper Windows version instead) at the moment. Additionally I will use MAMP (Mac, Apache, MySQL, PHP stack), of course there are other possible solutions like WampServer for Windows, multiplatform XAMPP, or Zend Server.

Download links:

- Eclipse IDE for Java EE Developers – http://www.eclipse.org/downloads/

- Eclipse PDT 2.1 (pdt-Update-2.1.2.zip) – http://www.eclipse.org/pdt/downloads/

- Java SE Development Kit (JDK 6 Update 17 – at the moment) – http://java.sun.com/javase/downloads/index.jsp

- Flash Builder 4 Plug-in Beta 2 – https://www.adobe.com/cfusion/entitlement/index.cfm?e=labs_flashbuilder4 (you need to login with a free Adobe ID account)

- ZendDebugger (download latest version depending your operating system) – http://downloads.zend.com/pdt/server-debugger/

- MAMP, WAMP, XAMPP, or Zend Server
http://www.mamp.info/
http://www.wampserver.com/
http://www.apachefriends.org/en/xampp.html
http://www.zend.com/en/products/server-ce/

Installation steps:

Step 1) Start with Eclipse IDE for Java EE Developers installation, it is as simple as unpacking it to some folder on your drive. If you are on Windows make sure you have the JDK (Java Development Kit) installed on your system. Without that Eclipse will not run.

Step 2) Run Eclipse from the folder you installed it in. A clean installation will start with welcome screen; select Workbench option in the right upper corner to go directly to the development environment.

Step 3) Install PDT 2.1 as described in the following section of the PDT installation wiki: http://wiki.eclipse.org/PDT/Installation#Eclipse_3.5_.2F_Galileo_.2F_PDT_2.1

IMPORTANT DON’T INSTALL PDT 2.2 AT THE MOMENT as it has some bugs that are causing PHP scripts to crash. Go to the link  at the top and download one marked on a picture below (pdt-Update.2.1.2.zip):

pdt-download-link
As described in the wiki link above, in Eclipse go to Help > Install New Software… > Add… > Name: PDT, Location: jar:file:/path/to/pdt-Update-2.1.2.zip!/

pdt-Update.zip
Step 4) Install Flash Builder 4 Plug-in Beta 2 pointing to the Eclipse installation that was unpacked earlier, as shown below:eclipse-fb4

Step 5) Now you are ready to run your PHP/Flex development environment. Just remember NOT TO run it with the links provided by the Flash Builder 4 Plug-in installation. IMPORTANT: Directly start Eclipse from the folder you unpacked it into.

You can switch to the PHP or Flash perspective in upper right corner of your Eclipse Workbench by selecting it from the list in the Other option.

swith-perspective

Step 6) Install the Apache, MySQL, PHP stack. Unpack ZendDebugger downloaded from one of the links above. Follow the instructions in README file to install it on your system.

Alternatively you can use ZendExtensionManager and configure it this way in your php.ini file:

zend_extension_manager.debug_server=/Applications/MAMP/bin/php5/zend/lib/ZendDebugger-5.2.15
zend_debugger.allow_hosts=127.0.0.1
zend_debugger.expose_remotely=always

IMPORTANT: ZendDebugger-5.2.15 is the unzipped ZendDebugger package and its subfolders need to be renamed to follow this schema: php-5.2.x. For example: 5_2_x_comp => php-5.2.x

Just remember to drop dummy.php into your website public root folder on your dev environment.

Step 7) Create your PHP project and give it a Flex Project nature by right clicking on your PHP project and selecting option Add/Change Project Type > Add Flex Project Type. This way you can have all your code in one single project. Of course you can have two separate projects for PHP and Flex but this is your decision. Do what will be more convenient for you.

flex-nature

And now you can Rock & Roll with PHP and Flex!

Written by Piotr Walczyszyn

December 3rd, 2009 at 12:44 pm

Posted in Articles

Tagged with , ,

e-Government RIA manifesto

without comments

Last week I was presenting at MAX 2009 in LA where I talked about Flex and Adobe AIR in Government, it was based on e-Deklaracje Desktop application released by Polish Ministry of Finance (you can find more info about e-Deklaracje Desktop in one of my previous posts here). Important here is to note that e-Deklaracje received Honorable Mention in Adobe 2009 MAX Awards.  My presentation was focusing on requirements, challenges and solutions that Ministry of Finance faced during implementation of e-Deklaracje. Here is the link to video of my presentation online. At the end I concluded with my personal manifesto that I believe e-Government Rich Internet Applications should be guided by to achieve success! Manifesto is made of four mandatory bullets that are in totally random order but each as equal in its value:

Consistency – application should work consistently on all major operating systems, browsers or even hardware without compromises. Citizens should have freedom of using different environments and achieve same user experience.

Openness – the architecture of the application should be open and available to the public. Preferably it should use communication channels and formats based on open standards e.g. HTTP, SOAP, AMF or JASON. These commodities will make integration and extensions easier for the public.

Experience – citizens’ experience should be as straightforward as possible and that applies to anything like usage, accessibility or installation procedures. Actually experience should engage and drive the user through the application.

Security – this is the most obvious one but shouldn’t be forgotten. User data should be secure not only on server side or over communication channels but also on the client side. Encryption to storage or access should be applied where possible, giving the user confidence while using the application.

Any comments are most likely welcome. RIA is trend now that whole industry is going towards and as citizens and users of e-Government applications we should expect same from public institutions solutions.

Written by Piotr Walczyszyn

October 13th, 2009 at 4:16 pm

Posted in Articles

Tagged with , ,

Interview with me in Belorussian “Computer News”

with one comment

Last week Belorussian “Computer News” newspaper has published interview with me, here is the electronic version: http://kv.by/index2009354301.htm I encourage anyone to read, especially if you know Russian :) – sorry for the mistake in the beginning with Belorussian

Written by Piotr Walczyszyn

September 21st, 2009 at 11:46 am

Posted in Articles

Adobe AIR in government institutions (e-Deklaracje Desktop)

with 7 comments

At the beginning of April (09.04.2009) Polish Ministry of Finance released their first Adobe AIR based application e-Deklaracje Desktop. This application lets its users submit annual tax declarations electronically and monitor their status. In Polish tax legislation every citizen is obliged to settle his income for previous year with tax office by the end of April. Historically e-Deklaracje project was initiated by Ministry of Finance in 2007/2008 but with less success and wide range adoption due to electronic signature requirement. By that time it required special hardware readers for digital signatures that are not commonly adopted in Poland.

This year Ministry of Finance has prepared change in legislation that was later signed by President of Republic of Poland that allowed sending annual declarations without qualified digital signature. Still to ensure proper security level users had to provide their personal information like: first name, last name, date of birth, NIP – tax identification number, PESEL – personal identification number and declared income from previous year. In reality this set of information is more than it was required in traditional paper based declarations (that’s the case with income from last year). I guess all this information gives better identity verification than traditional way where anyone can send his declaration by post or bring it in person to tax office (where no one asks for any id).

After only three weeks of availability over 77000 citizens have sent their declarations electronically (UPDATE 18.05: latest information from MF website states that 89000 declarations were sent, I guess those that forgot to do it till the end of April are still submitting)!!! This is incredible result taking into consideration such a short time, I believe next year we can expect this number to multiply couple times when people will have it available since January.

I’m also proud to say that local Adobe team (Tadeusz Chełkowski, Tomasz Lichota, Bartek Soin and of course myself) supported this project from very beginning with our technical and RIA experties.

Why Adobe AIR?

Ministry of Finance had couple of major requirements that had to be met by that type of application:

  1. Cross-platform support – solution had to work without any compromises on all major operating systems like: Windows, Mac OS X and Linux.
  2. Usability – it had to be easy to install and natural to use for inexperienced users. With badge installer on MF website it just couldn’t be made easier.
  3. Security – give the users confidence that application they are installing was really issued by Ministry of Finance.
  4. Interoperability – integration with SOAP based backend services.
  5. PDF forms support – already existing PDF forms developed in previous year could be reused with small adjustments supporting non-qualified signature.
  6. Desktop integration – required desktop features:
  • Reliable local storage for drafts and sent declarations offline persistence;
  • PDF forms templates and documentation local caching;
  • Notifications mechanism for asynchronous confirmations (declarations receiving and confirmations service works in asynchronous mode with response time up to 24 hours).

As you can see all of above make Adobe AIR perfect fit for that type of applications. In my opinion the most important features in case of any application issued by public sector institutions are: cross-platform support, usability and security.

We had some stories in Poland in the past of applications written only for Windows platform with closed protocol specifications that ended with Linux users taking legal actions against publishing institutions. Adobe AIR built-in cross-platform support resolves this issue, I actually observed very positive feedback especially on Linux forums after e-Deklaracje release. Some comments stated that this is first time Polish government institution has noticed that there are also other OS’s than Windows.

In terms of usability there are two important factors, first of all installation process to make it as smooth as possible, ideally with small footprint, dependent runtime, tools and libraries automatic detection and installation (badge installer was resolving most of these, except Adobe Reader installation). Another factor is availability of experienced UI designers and developers. This is Adobe’s strong field with great community of Flash and UI design experts.

From the security perspective for application that gathers and sends out user personal information is important to give users confidence that the application was distributed by trusted entity and any communication with backed services is done through secure encrypted channels. Application issuer verification is Adobe AIR built-in feature with signed install packages.

You can check it out yourself on MF website: http://www.e-deklaracje.gov.pl/index.php?page=do_pobrania

This is how the application looks:

e-Deklaracje Desktop main window

Declaration fill window

History window

Written by Piotr Walczyszyn

May 14th, 2009 at 11:47 am

Posted in Articles,Examples,Releases

Tagged with ,

Flex with full Zend Framework on Adobe Developer Connection (part 2)

with 3 comments

It was actually published last week but I just found some time to write about it on my blog. Its a part 2 of my ADC series about Zend Framework for Flex developers:

Recording is also available directly on Adobe TV website and iTunes.

Written by Piotr Walczyszyn

April 27th, 2009 at 9:59 pm

Posted in Articles,Examples

Tagged with , , ,

Encoding options for H.264 video

without comments

Anyone interested in video encoding stuff and especially in H.264 should check out new article on ADC: http://www.adobe.com/devnet/flashmediaserver/articles/h264_encoding.html

Written by Piotr Walczyszyn

March 17th, 2009 at 9:49 am

Posted in Articles

Flex Developer Tools – MVC & DI Frameworks

with 2 comments

I was recently sidetracked by some other activities but I’m back with my research on Flex Developer Tools. Today I wanted to share couple of my findings in MVC & DI (Dependency Injection) frameworks area. Again I’m looking for your feedback with experiences and maybe missing things. As you can see we have 100% Open Source products here. I guess this is similar to testing, mocking and code coverage stuff.

  • Cairngorm (Adobe Open Source) – Its a very powerful MVC framework that comes from Adobe, a lot of Adobe Flex/AIR based products especially those built by Adobe Consulting are using this one.
  • PureMVC (Open Source) – MVC framework, very famous in this league, interesting that they even ported that to Objective C for iPhone development – cool!!! So now we Flex devs should have easier live there ;)
  • Mate (Open Source) – Mate is a tag-based, event-driven Flex framework
  • Swiz (Open Source) – Metadata-based Dependency Injection framework, this is my winner, I really love it. In some way it reminds me of Seam Framework from Java/JBoss camp. With simple metadata annotations you can inject your controllers, components, config items etc. It has also metadata driven eventing capabilities, you can annotate event handler methods. Couple of other neat features like command chaining, slick RemoteObject delegate handling…
  • Spring ActionScript (Open Source) – DI framework part of SpringSource ,formerly known as Prana Framework. Very much like Spring but for Flex, similar configuration and approach. I think it is a very interesting and worth giving it a test drive…

Here are the link to my previous posts in Flex Developer Tools series:

Read the rest of this entry »

Written by Piotr Walczyszyn

January 29th, 2009 at 5:27 pm

Posted in Articles

Tagged with

How-to use Text Layout Framework

without comments

Some time ago I was writing about how-to use latest Text Layout Framework but this time Mihai Corlan did excellent job and went down into very details, any one interested in TLF should read this one: http://corlan.org/2009/01/19/how-to-use-text-layout-framework-in-flex-32-or-air-15/

Written by Piotr Walczyszyn

January 19th, 2009 at 2:55 pm

Posted in Articles

Tagged with ,

Flex Developer Tools – Testing, Mocking and Code Coverage

with 14 comments

This is next post of the “Flex Developer Tools” series, this time I’m covering Testing, Mocking and Code Coverage. In this category the winner is Open Source ;) as opposed to IDE category where we have more commercial tools. Again I would like to hear what are your thoughts and experience with these tools, frameworks and libraries.

  • FlexUnit (Adobe Open Source) – conceptually based on famous JUnit
  • Funit (Open Source) – Metadata Driven Unit Testing for Flex
  • asUnit (Open Source) – Unit Testing Framework
  • fluint (Open Source) – I never had a chance to use this one but it seems to be very impressing and I’m looking forward to give it a try in my next project. “It provides full support for unit testing in the tradition of FlexUnit, but goes further with richer asynchronous support and support for integration-level testing.”
  • FunFX (Open Source) – Cool: “A Ruby tool for functional testing of Adobe Flex applications
  • FlexMonkey (Open Source) – UI testing, capture replay
  • Selenium (Open Source) – API for Selenium
  • FlashSelenium (Open Source) – Selenium RC Client driver extension
  • mock-as3 (Open Source) – mock object library

Written by Piotr Walczyszyn

January 15th, 2009 at 12:54 pm

Posted in Articles

Tagged with

Switch to our mobile site