我有一个swf,由于某种原因,它有四个RemoteObjects指向同一个ChannelId,但它们将该通道列为两个不同的位置。在五个RemoteObject中的四个中,一切都按预期运行,但在第四个(WidgetService)中,dev上的版本从dev.context.root切换到loc.context.root。更令人困惑的是,它只在开发服务器上执行此操作(质量保证和生产都很好,本地构建也是如此)。
配置文件中的相关信息如下:
#This is from build.properties, which is used by Ant #to build the swf on the server flex.sdk.dir = /path/to/sdk/flex_sdk_3.2.0.3958 flex.sdk.bin.dir = ${flex.sdk.dir}/bin flex.sdk.framework.dir = ${flex.sdk.dir}/frameworks flex.sdk.libs.dir = ${flex.sdk.framework.dir}/libs flex.sdk.locale.dir = ${flex.sdk.framework.dir}/locale/{locale} flex.sdk.locale = en_US loc.context.root = /somename-1.0.4.0000 dev.context.root = /dev-somename qa.context.root = /somename prod.context.root = / #this value is changed based on the build. context.root = ${dev.context.root}
<!-- All of the RemoteObjects are directed here -->
<channel-definition id="my-amf" class="mx.messaging.channels.AMFChannel">
<endpoint url="http://{server.name}:{server.port}/{context.root}/messagebroker/amf" class="flex.messaging.endpoints.AMFEndpoint"/>
</channel-definition>
<!-- A list of the services -->
<destination id="UserService">
<properties>
<factory>spring</factory>
<source>userService</source>
</properties>
<channels>
<channel ref="my-amf"></channel>
</channels>
</destination>
<destination id="SystemService">
<properties>
<factory>spring</factory>
<source>systemService</source>
</properties>
<channels>
<channel ref="my-amf"></channel>
</channels>
</destination>
<destination id="SessionService">
<properties>
<factory>spring</factory>
<source>sessionService</source>
</properties>
<channels>
<channel ref="my-amf"></channel>
</channels>
</destination>
<destination id="VistorService">
<properties>
<factory>spring</factory>
<source>visitorService</source>
</properties>
<channels>
<channel ref="my-amf"></channel>
</channels>
</destination>
<destination id="WidgetService">
<properties>
<factory>spring</factory>
<source>widgetService</source>
</properties>
<channels>
<channel ref="my-amf"></channel>
</channels>
</destination>
答案 0 :(得分:0)
事实证明,另一个开发人员使用项目的本地配置而不是服务器配置构建了一个在运行时加载的swf。