4 Replies Latest reply on Apr 17, 2007 1:53 AM by PowerHorse

    Error invoking fill-method 'fill'

    pwp69 Level 1
      I am following the instructions at www.adobe.com/devnet/flex/articles/coldfusionflex_part1.html to connect the sample contact application to coldfusion.

      When I invoke the application the grid and form appear. Ater a few seconds I get a alert box with:
      Error invoking fill-method 'fill' for destination cfcontact: Permission denied.

      How to I grant permission to this destination?

        • 1. Re: Error invoking fill-method 'fill'
          tomj Adobe Employee
          You would need to configure the IP address of the server in the Flex destination and in the CF administrator Flex Integration page. By default only Flex on the local machine is allowed to connect to ColdFusion. If you are running Flex andCF on the same machine, try explicitly configuring the real IP address (not 127.0.0.1) on both the destination (data-maangement.xml) and in the CF admin page.

          Hope that helps.
          • 2. Re: Error invoking fill-method 'fill'
            pwp69 Level 1
            Thank you for the reply, Tom. I decided to try working through your 'Using Coldfusion with Flex - Part 2:...' CRM app to learn how Flex/CF works.

            I believe I followed your instructions to the letter. It this case I get the "Error invoking fill-method 'fill' for destination cfcompany: Permission denied." error even on a browser running on the FDS/CF server"

            The ip address of the server FDS and CF are running on is 192.168.1.99. This IP is registered in CFAdmin and in each of the data-management-config.xml destinations.

            <!-- ======================================== -->
            <!-- ColdFusion Sample - employee for the CRM sample -->
            <!-- ======================================== -->
            <destination id="cfemployee">

            <adapter ref="coldfusion-dao"/>
            <channels>
            <channel ref="cf-dataservice-rtmp"/>
            <channel ref="cf-polling-amf"/>
            </channels>

            <properties>
            <component>crm.EmployeeAssembler</component>
            <scope>application</scope>
            <!-- The hostname or IP address of the CF host.
            Optional, default is localhost. -->
            <hostname>192.168.1.99</hostname>
            <metadata>
            <identity property="employeeId"/>
            </metadata>
            </properties>
            </destination>

            <!-- ======================================== -->
            <!-- ColdFusion Sample - company for the CRM sample -->
            <!-- ======================================== -->
            <destination id="cfcompany">

            <adapter ref="coldfusion-dao"/>
            <channels>
            <channel ref="cf-dataservice-rtmp"/>
            <channel ref="cf-polling-amf"/>
            </channels>

            <properties>
            <component>crm.CompanyAssembler</component>
            <scope>application</scope>
            <!-- The hostname or IP address of the CF host.
            Optional, default is localhost. -->
            <hostname>192.168.1.99</hostname>
            <metadata>
            <identity property="companyId"/>
            </metadata>
            </properties>
            </destination>


            The FDS console's error message is as follows:

            [Flex] {Error] Exception when invoking service: data-service with message:
            Flex Message (flex.data.messages.DataMessages)
            operation = fill
            id = null
            clientId = <UUID here - pwp>
            destination = cfcompany
            messageID = <UUID here - pwp>
            timestamp = 1154988936031
            timeToLive = 0
            body =
            [

            ]
            hdr(DSEndpoint) = cf-dataservice-rtmp
            exception: flex.data.adapters.AdapaterException: Error invoking fill-method 'fill' for destination cfcompany: Permission denied.

            I see in services-config.xml there is a security tag.

            <security>
            <security-constraint id="sample-users">
            <auth-method>Custom</auth-method>
            <roles>
            <role>sampleusers</role>
            </roles>
            </security-constraint>

            <login-command class="flex.messaging.security.JRunLoginCommand" server="JRun"/>
            <!-- Uncomment the correct app server
            <login-command class="flex.messaging.security.TomcatLoginCommand" server="Tomcat"/>
            <login-command class="flex.messaging.security.WeblogicLoginCommand" server="Weblogic"/>
            <login-command class="flex.messaging.security.WebSphereLoginCommand" server="WebSphere"/>
            -->
            </security>

            Do I have to do something with it?


            Any help would be appreciated.




            • 3. Re: Error invoking fill-method 'fill'
              tomj Adobe Employee
              Make sure you have configured the ColdFusion server to accept connections from the Flex machine. If you are runing these on the same machine, there should be no problem. If you are on different machines, go the the "Flex Integration" page of the CF administrator. Add the IP address of your Flex server using this page.
              • 4. Re: Error invoking fill-method 'fill'
                PowerHorse
                Hi Tom,

                I'm having the same error when the form is loaded.
                It says Error invoking fill-method 'Fill' for destination cfcontact:Unable to invoke CFC

                Can you please help me out also.

                Thanks and Regards,
                Ajustin