Skip to content

joshtynjala/blazeds-turnkey-archive

Repository files navigation

BlazeDS Turnkey Bundle Archive

Before Adobe donated BlazeDS to the Apache Flex project, Adobe BlazeDS releases included a special "turnkey" bundle that included a pre-configured version of Apache Tomcat and a number of samples — to demonstrate how to use BlazeDS on the server with Apache Flex on the client.

Adobe no longer makes this turnkey bundle available for download. However, because the bundle was released under an open source license, this archive was created to ensure that its included sample applications remain available as a reference for learning purposes.

Warning! This bundle contains the original (now outdated) versions of Adobe BlazeDS 4.0.0.14931 and Apache Tomcat 6.0.14. These should not be used in production, as they may contain security vulnerabilities. For real-world apps, you should upgrade to the latest versions of BlazeDS and Tomcat.

What is BlazeDS?

BlazeDS is the server-based Java remoting and web messaging technology that enables developers to easily connect to back-end distributed data and push data in real-time to front-end applications for more responsive rich web application experiences.

BlazeDS uses AMF (Action Message Format), a form of binary encoding to serialize Java object graphs on the remote server and transfer them to the client (which may be written in JavaScript or another language) to be deserialized, reproducing the same object graph that exists on the server. One of the advantages of AMF is being able to serialize the data in a more compact way than common plain text data formats, like JSON or XML, which means that sending AMF data over a network requires less bandwidth.

Is Adobe Flash Player required?

The original front-end sample Flex applications included in this bundle require the Adobe Flash Player plugin to run. As of 2020, Adobe has discontinued Flash Player updates, and they no longer make old versions of the plugin available for download. Additionally, most web browsers have completely removed support for displaying content using plugins.

However, these front-end samples have been recreated with other technologies that can compile to JavaScript for the web, so that no plugins are required. Choose your favorite alternative from the ones below.

Upgrade BlazeDS

The original bundle includes Adobe BlazeDS 4.0.0.14931, which is outdated and contains known security vulnerablities. New releases of BlazeDS are now managed by the Apache Flex project.

  1. Download the BlazeDS source or binary release.
  2. Extract the BlazeDS release somewhere on your computer.
  3. If you downloaded the source release, follow the instructions to build BlazeDS. If you downloaded the binary release, it will include pre-built .jar files.
  4. Collect the compiled flex-messaging-*.jar files, and all dependencies, and replace everything except hsqldb.jar in the webapps/samples/WEB-INF/lib directory.

Upgrade Tomcat

The original bundle includes Apache Tomcat 6.0.14, which may not be fully compatible with modern environments. Before getting started, you may need to upgrade Tomcat to a newer version.

Tomcat 9

The existing samples are compatible with Tomcat 9. Follow these steps to upgrade.

  1. Delete everything except the webapps subdirectory inside the tomcat directory of the extracted BlazeDS Turnkey bundle.
  2. Download a Tomcat 9 binary distribution for your operating system.
  3. Extract the Tomcat binary distribution somewhere on your computer.
  4. Copy everything except the webapps subdirectory from the extracted Tomcat binary distribution to the tomcat directory of the extracted BlazeDS Turnkey bundle.

Tomcat 10

Upgrading to Tomcat 10 or newer requires one additional step because the existing samples need to be migrated from Java EE to Jakarta EE, as explained in the Tomcat 10 Migration Guide. Thankfully, most of the work is done by an automated tool built into Tomcat.

If you're going to upgrade both BlazeDS and Tomcat 10, upgrade BlazeDS first. Tomcat 10's automated migration needs to process the BlazeDS .jar files too.

  1. Delete everything except the webapps subdirectory inside the tomcat directory of the extracted BlazeDS Turnkey bundle.
  2. Rename the existing webapps subdirectory to webapps-javaee. This will cause the automated migration process to trigger when you start the server.
  3. Download a Tomcat 10 binary distribution for your operating system.
  4. Extract the Tomcat binary distribution somewhere on your computer.
  5. Copy everything except the webapps subdirectory from the extracted Tomcat binary distribution to the tomcat directory of the extracted BlazeDS Turnkey bundle.

After successfully starting the Tomcat server, you can delete the webapps-javaee directory.

Usage

Follow these steps to start a local development server.

  1. Download and extract blazeds-turnkey-4.0.0.14931.zip.

  2. Upgrade the bundled Tomcat server using the appropriate instructions above for your chosen version.

  3. Upgrade the bundled BlazeDS binaries using the instructiosn above.

  4. Open a terminal, and navigate to the directory where the BlazeDS Turnkey bundle was extracted.

  5. Use the provided startup script to start Tomcat.

    On Windows, run .\tomcat\bin\startup.bat

    On macOS or Linux, run ./tomcat/bin/startup.sh

  6. If the server started successfully, you should see the text Tomcat started. in the terminal output.

  7. Open a web browser, and navigate to the following URL: http://localhost:8080/samples/ to see a page explaining the BlazeDS samples.