5 Replies Latest reply on Jul 12, 2007 2:08 PM by Newsgroup_User

    Flex 2, FDS 2.5 and CF8

    cyber fyb Level 1
      Hi everyone,

      I am starting to retract my brain from an intense 2 days to figure out how to use Flex with Coldfusion. I am using Coldfusion 8 Beta (this part is good, don't need help for CF itself). I am also using Flex Builder 2 (with chart but this not the topic). I installed FDS 2.5 before to install ColdFusion 8 but I think CF8 have is own FDS or something like that... anyway, it might help to mention it!

      Well, I tried HTTPService, RemoteObject, WebSer vice - NOTHING WORKS!!! Argh! Did I mention I spent 2 days? ;-)))

      Well, I start with the basic: a login form with an email (as a username) and a password to be validated. I have a CFC to do the validation and return a simple message (string): "OK' when it is valid and a custom message when it is not valid; depending if it is the password and/or the email which is not valid.

      I always got an error. Since the error is different depending of the method I use, I will explain the latest method I used in this message and try to concentrate on that method specifically! The method is WebService and here is the error:

      faultString:'HTTP request error'
      faultDetail: 'Error: [IOErrorEvent type="ioError"
      bubbles:false cancelable=false eventPhase=2
      text="Error #2032: Stream Error . URL=http://localhost:8501/iDashboard/login.cfc"].
      URL: http://localhost:8501/iDashboard/login.cfc'

      Any help will be very useful!!!


      P.S.: I succeed to execute a HTTPService only if I call a XML file.
        • 1. Re: Flex 2, FDS 2.5 and CF8
          Level 7
          Calling CF WebServices from Flex shouldn't involve FDS unless you're using
          the Proxy Service (which is only really needed if you can't host your SWFs
          on the same CF server or can't establish a crossdomain.xml file). Are you
          using the FDS proxy service to contact this WebService?

          If so, can you look at the server console when you start up ColdFusion and
          check that there weren't any configuration errors?

          • 2. Re: Flex 2, FDS 2.5 and CF8
            cyber fyb Level 1
            Hi, first, thank you for the reply - I feel lessa lone now!

            I know that WebService is not require FDS as I read it and this is partially why I do not understand why it is not working as it is suppose to be very simple!!!

            Before answer your reply, I will just say that I installa Flex Builder 2 and than FDS 2.5 and than ColdFusion 8. I though all the XML file for setup will be ajsuted automatically by all these installations since I am not so familiar with "changing setup XML file". Don't get me wrong, it is not that I do not understand XML language but never had (since I am a ColdFusion programmer) to play very much with those files. I understand, from all the reading I did to learn Flex, that tose files can give confusion at some point as Flex as is own XML and ColdFusion also. So, the bottom line is that I did not touch the XML file and this mean that I do not use any proxydomain.xml other than the "default" one - if any exist.

            As for the ColdFusion 8 startup - I think you point to something interesting as I got an eror. Here is the error when I start the service through cmd.exe (I am using Windows):

            ERROR: transport error 202: bind failed: Address already in use
            ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
            JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [../../../src/share/back/debugInit.c:690]
            FATAL ERROR in native method: JDWP No transports initialized, jvmtiError=AGENT_E

            I will start to look from my side through Google what I can find about this but if you have any hint to help me, do not hesitate to let me know!!!

            Thank you very much.
            • 3. Re: Flex 2, FDS 2.5 and CF8
              cyber fyb Level 1
              Sorry, I made a mistake as the error mentioned before is not a real error. It was an error because the service of ColdFusion 8 was not really stopped!

              It has no error:

              Listening for transport dt_socket at address: 5005
              Starting Macromedia JRun 4.0 (Build 108472), coldfusion server
              07/12 14:36:40 warning Unable to open C:\ColdFusion8\runtime/lib/license.propert
              07/12 14:36:41 info JRun Naming Service listening on *:2930
              07/12 14:36:42 info No JDBC data sources have been configured for this server (s
              ee jrun-resources.xml)
              07/12 14:36:42 info JRun Web Server listening on *:8501
              07/12 14:36:42 info Deploying enterprise application "Adobe_ColdFusion_8" from:
              07/12 14:36:42 info Deploying web application "Adobe ColdFusion 8" from: file:/C
              07/12 14:36:44 INFO License Service: Flex 1.5 CF Edition enabled
              07/12 14:36:44 user JSPServlet: init
              07/12 14:36:44 INFO Starting Flex 1.5 CF Edition
              07/12 14:36:45 user ColdFusionStartUpServlet: init
              07/12 14:36:45 user ColdFusionStartUpServlet: ColdFusion: Starting application s
              07/12 14:36:45 user ColdFusionStartUpServlet: ColdFusion: VM version = 1.6.0_01-
              07/12 14:36:45 Information [main] - Starting logging...
              07/12 14:36:45 Information [main] - Starting license...
              07/12 14:36:47 Information [main] - Invalid ColdFusion 8 license.
              07/12 14:36:47 Information [main] - Developer Edition enabled
              07/12 14:36:47 Information [main] - Starting crypto...
              07/12 14:36:47 Information [main] - Starting security...
              07/12 14:36:47 Information [main] - Starting scheduler...
              07/12 14:36:47 Information [main] - Starting WatchService...
              07/12 14:36:47 Information [main] - Starting debugging...
              07/12 14:36:47 Information [main] - Starting sql...
              07/12 14:36:47 Information [main] - Pool Manager Started
              07/12 14:36:48 Information [main] - Starting mail...
              07/12 14:36:48 Information [main] - Starting runtime...
              07/12 14:36:48 Information [main] - CORBA Configuration not enabled
              07/12 14:36:48 Information [main] - Starting cron...
              07/12 14:36:48 Information [main] - [Synchro PrivateDNS Basic Data] has run once
              before, and will not be scheduled.
              07/12 14:36:48 Information [main] - Starting registry...
              07/12 14:36:48 Information [main] - Starting client...
              07/12 14:36:49 Information [main] - Starting xmlrpc...
              07/12 14:36:49 Information [main] - Starting graphing...
              07/12 14:36:49 Information [main] - Starting verity...
              07/12 14:36:49 Information [main] - Starting archive...
              07/12 14:36:49 Information [main] - Starting document...
              07/12 14:36:49 Information [main] - Starting eventgateway...
              07/12 14:36:49 Information [main] - Starting Event Backend Handlers.
              07/12 14:36:49 Information [main] - Initialized EventRequestDispatcher with a Th
              read Pool size of 1.
              07/12 14:36:49 Information [main] - Initializing EventRequestHandler
              07/12 14:36:49 Information [main] - Starting Event Gateways.
              07/12 14:36:49 Information [main] - Starting FlexAssembler...
              07/12 14:36:50 Information [main] - Starting .NET...
              07/12 14:36:50 Information [main] - Starting Monitoring...
              07/12 14:36:50 Information [main] - ColdFusion started
              07/12 14:36:50 user ColdFusionStartUpServlet: ColdFusion: application services a
              re now available
              07/12 14:36:50 user CFMxmlServlet: init
              07/12 14:36:50 user CFMxmlServlet: Macromedia Flex Build: 87315.134646
              07/12 14:36:50 INFO Macromedia Flex Build: 87315.134646
              07/12 14:36:52 user CFSwfServlet: init
              07/12 14:36:53 user CFCServlet: init
              07/12 14:36:53 user FlashGateway: init
              07/12 14:36:53 user MessageBrokerServlet: init
              07/12 14:36:56 user CFFormGateway: init
              07/12 14:36:56 user CFInternalServlet: init
              Server coldfusion ready (startup time: 19 seconds)
              • 4. Re: Flex 2, FDS 2.5 and CF8
                Level 7
                You say you have Flex Builder 2, but is it Flex Builder 2.0.1 Hotfix 2? You
                really should have this version when working with LCDS 2.5 or CF8.


                • 5. Re: Flex 2, FDS 2.5 and CF8
                  Level 7
                  Some other things to check come to mind....

                  If your CF server is at http://localhost:8501/... is there a context-path
                  for the cf war file? If so, is it /iDashboard?

                  For RemoteObject or proxied HTTPService/WebService, did you point Flex Builder
                  at your /WEB-INF/flex/services-config.xml file with the -services command
                  line compiler argument? If so, then did you remember to specify the -context-root
                  command line compiler argument too as it's likely that you've still got {context.root}
                  tokens in your services-config.xml channel-definition endpoint urls, say

                  Also, how are you loading your SWF to view the flex application? Does the
                  SWF reside on the same ColdFusion server? Remember that to the SWF security
                  sandbox, a server name of "localhost" is not equivalent to "" -
                  make sure you use the exact same server name in loading the SWF and making
                  connections to remote servers.

                  If it's not the same server, you may need a crossdomain.xml policy file.