The Petmarket example of using AMF::Perl

(shamelessy borrowed from Macromedia, who in their turn were inspired by Sun Blueprints)

To prevent your confusion, note that Macromedia has several Petmarket implementation. One of them is an HTML front-end to ColdFusion or J2EE servers like JRun. However, we are only interested in the Flash front-end that communicates via Flash Remoting with a Java back-end. Macromedia distributes a small Java layer that sits between Sun's J2EE Petstore monster and the client.

I have rewritten this small layer, implementing the full J2EE functionality in about 50 K of Perl code. :) Seriously, the original Sun application included not just the customer interface, but also order processing, warehouse linkages and the whole works. Macromedia only did the user front-end, which is what you will find here.

Here is the Petmarket application with Perl back-end.

For comparison, this is the original Macromedia application with Java back-end.

The server code can be found in the doc/examples directory of the AMF::Perl distribution.

The compiled client code is here, though you can get the uncompiled original from Macromedia's site. Remember that you'll have to change the URL of the server in initFunctions/