0 Replies Latest reply on Jun 5, 2008 1:46 PM by thais.flory

    Destination not accessible over channel 'my-cfamf'

    thais.flory
      I've been getting the error below occasionally, it seems to only happen after I've been testing my Flex app for a while without reloading the browser.

      ==
      faultCode:Server.Processing faultString:'Destination 'IntermediaryConversionEnvironment' not accessible over channel 'my-cfamf'.' faultDetail:'null'

      [RPC Fault faultString="Destination 'IntermediaryConversionEnvironment' not accessible over channel 'my-cfamf'." faultCode="Server.Processing" faultDetail="null"]
      at mx.rpc::AbstractInvoker/ http://www.adobe.com/2006/flex/mx/internal::faultHandler()
      at mx.rpc::Responder/fault()
      at mx.rpc::AsyncRequest/fault()
      at ::NetConnectionMessageResponder/NetConnectionChannel.as$40:NetConnectionMessageResponder: :statusHandler()
      at mx.messaging::MessageResponder/status()
      ==

      An interesting observation is that my "IntermediaryConversionEnvironment" destination is not associated with channel "my-cfamf" in the services-config.xml. It's almost as if the Flash Remoting service is mixing up the destination and the channel at some point during execution.

      In my Flex code, I'm only setting the remote object's destination property (which gets dynamically switched back and forth between my 2 destinations at runtime), I'm not setting the channels anywhere.

      We have a the main CF server instance, where my swf is, which maps to the CFC remote objects.
      And we have a secondary CF server instance on port 8081, whose mapping also points to the same CFCs.
      Both services-config.xml files have the same exact content, which is:

      ==
      <?xml version="1.0" encoding="UTF-8"?>
      <services-config>

      <services>
      <service id="coldfusion-flashremoting-service"
      class="flex.messaging.services.RemotingService"
      messageTypes="flex.messaging.messages.RemotingMessage">

      <adapters>
      <adapter-definition id="cf-object" class="coldfusion.flash.messaging.ColdFusionAdapter" default="true"/>
      </adapters>

      <destination id="ColdFusion">
      <channels>
      <channel ref="my-cfamf"/>
      <channel ref="my-secure-cfamf"/>
      </channels>
      <properties>
      <source>*</source>
      <!-- define the resolution rules and access level of the cfc being invoked -->
      <access>
      <!-- Use the ColdFusion mappings to find CFCs, by default only CFC files under your webroot can be found. -->
      <use-mappings>true</use-mappings>
      <!-- allow "public and remote" or just "remote" methods to be invoked -->
      <method-access-level>remote</method-access-level>
      </access>

      <property-case>
      <!-- cfc property names -->
      <force-cfc-lowercase>false</force-cfc-lowercase>
      <!-- Query column names -->
      <force-query-lowercase>false</force-query-lowercase>
      <!-- struct keys -->
      <force-struct-lowercase>false</force-struct-lowercase>
      </property-case>
      </properties>
      </destination>
      <destination id="IntermediaryConversionEnvironment">
      <channels>
      <channel ref="intermediaryConversionEnv-cfamf"/>
      </channels>
      <properties>
      <source>*</source>
      <!-- define the resolution rules and access level of the cfc being invoked -->
      <access>
      <!-- Use the ColdFusion mappings to find CFCs, by default only CFC files under your webroot can be found. -->
      <use-mappings>true</use-mappings>
      <!-- allow "public and remote" or just "remote" methods to be invoked -->
      <method-access-level>remote</method-access-level>
      </access>

      <property-case>
      <!-- cfc property names -->
      <force-cfc-lowercase>false</force-cfc-lowercase>
      <!-- Query column names -->
      <force-query-lowercase>false</force-query-lowercase>
      <!-- struct keys -->
      <force-struct-lowercase>false</force-struct-lowercase>
      </property-case>
      </properties>
      </destination>

      </service>
      </services>

      <channels>
      <channel-definition id="my-cfamf" class="mx.messaging.channels.AMFChannel">
      <endpoint uri=" http://localhost:{server.port}{context.root}/flex2gateway/" class="flex.messaging.endpoints.AMFEndpoint"/>
      <properties>
      <polling-enabled>false</polling-enabled>
      <add-no-cache-headers>false</add-no-cache-headers>
      <serialization>
      <instantiate-types>false</instantiate-types>
      </serialization>
      </properties>
      </channel-definition>
      <channel-definition id="my-secure-cfamf" class="mx.messaging.channels.SecureAMFChannel">
      <endpoint uri="https://{server.name}:{server.port}{context.root}/flex2gateway/" class="flex.messaging.endpoints.SecureAMFEndpoint"/>
      <properties>
      <polling-enabled>false</polling-enabled>
      <add-no-cache-headers>false</add-no-cache-headers>
      <serialization>
      <instantiate-types>false</instantiate-types>
      </serialization>
      </properties>
      </channel-definition>
      <channel-definition id="intermediaryConversionEnv-cfamf" class="mx.messaging.channels.AMFChannel">
      <endpoint uri=" http://{server.name}:8081{context.root}/flex2gateway/" class="flex.messaging.endpoints.AMFEndpoint"/>
      <properties>
      <polling-enabled>false</polling-enabled>
      <add-no-cache-headers>false</add-no-cache-headers>
      <serialization>
      <instantiate-types>false</instantiate-types>
      </serialization>
      </properties>
      </channel-definition>
      </channels>

      <logging>
      <target class="flex.messaging.log.ConsoleTarget" level="Debug">
      <properties>
      <prefix>[Flex] </prefix>
      <includeDate>true</includeDate>
      <includeTime>true</includeTime>
      <includeLevel>true</includeLevel>
      <includeCategory>true</includeCategory>
      </properties>
      <filters>
      <pattern>Endpoint.*</pattern>
      <pattern>Service.*</pattern>
      <pattern>Configuration</pattern>
      <pattern>Message.*</pattern>
      </filters>
      </target>
      </logging>

      <system>
      </system>

      </services-config>
      ==

      Any help would be greatly appreciated, as any documentation I find online mentions only using the default ColdFusion destination, it doesn't seem there are a lot of people dynamically setting that property.

      Thais