0 Replies Latest reply on Jun 4, 2008 11:14 AM by Solerous

    AIR vs. Flex: image generator as a background process on the server

    Solerous Level 1
      I am running into problems with an image generator running on a headless server.

      When I start up the server, it launches my java app. It reads a list of report definitions from the data base. For each report, it spawns a thread. Each thread launches my Flex application in a browser window.

      Flex draws the data in charts. Each time data is pushed to the flex application from the java server side, Flex calls a remote java method to save it's image to a file. This file sits in a directory where it can be viewed in a regular old html page.

      The problem is really the automated aspect. I want to have this chart generated every few minutes as a .png file. It works perfectly fine on my localhost machine, but the server deployment is so far not working, I think because it is headless. We have firefox installed on the server. Is there no way to launch it as a background process to draw these images? Should I turn this into an AIR app (I've never done anything with AIR up to this point) to make it run more easily in the background?

      Java programmers all seem to think that running an image generating process in a web browser window on the server is "bad practice". So I think I am thinking maybe I should turn it into an AIR app. I'm not sure though how to deploy AIR apps though. Can they go in a .war file?

      If someone has any ideas about this or if going AIR is the wrong approach here please let me know. Thanks!