Granite数据服务:错误:[debug(模块MyModuleFlex)]:无法创建解析器来加载消息传递配置

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Granite数据服务:错误:[debug(模块MyModuleFlex)]:无法创建解析器来加载消息传递配置相关的知识,希望对你有一定的参考价值。

我将现有的Flex项目从eclipse迁移到IntelliJ。编译确定,调试确定。但是尚未定义应用程序。它使用Granite Data Service,我有一个定义通道的services-config.xml文件。

我编写了一个flex-config文件,然后尝试添加其他编译器选项:-services C:WorkspacesFlexMyModuleFlexservices-config.xml。在这两种情况下,我得到了错误:

Information:[debug (module MyModuleFlex)]: flex.messaging.LocalizedException: Unable to create a parser to load messaging configuration.
Information:[debug (module MyModuleFlex)]: at flex.messaging.config.ServicesDependencies.getClientConfiguration(ServicesDependencies.java:138)
Information:[debug (module MyModuleFlex)]: at flex.messaging.config.ServicesDependencies.<init>(ServicesDependencies.java:60)
Information:[debug (module MyModuleFlex)]: at flex2.compiler.common.CompilerConfiguration.getServicesDependencies(CompilerConfiguration.java:1247)
Information:[debug (module MyModuleFlex)]: at flex2.tools.Compiler.calculateServicesChecksum(Compiler.java:733)
Information:[debug (module MyModuleFlex)]: at flex2.tools.Compiler.processConfiguration(Compiler.java:670)
Information:[debug (module MyModuleFlex)]: at flex2.tools.Compiler.processConfiguration(Compiler.java:526)
Information:[debug (module MyModuleFlex)]: at flex2.tools.Compiler.mxmlc(Compiler.java:84)
Information:[debug (module MyModuleFlex)]: at flex2.tools.Compiler.main(Compiler.java:53)
Information:[debug (module MyModuleFlex)]: Compilation failed
Information:Some files were changed during the build. Additional compilation may be required.
Information:19/11/2019 10:54 - Build completed with 1 error and 0 warnings in 7 s 168 ms
Error:[debug (module MyModuleFlex)]: Unable to create a parser to load messaging configuration.

编译器配置:

<flex-config xmlns="http://www.adobe.com/2006/flex-config">
    <compiler>
        <locale>
            <locale-element>en_US</locale-element>
        </locale>
        <services>C:WorkspacesFlexMyModuleFlexservicesservices-config.xml</services>
    </compiler>
    <use-network>true</use-network>
</flex-config>

当然还有服务文件:

<?xml version="1.0" encoding="UTF-8"?>
<services-config>
    <factories>
        <factory id="springFactory"
            class="org.granite.messaging.service.SpringServiceFactory" />
    </factories>
    <services>
        <service id="granite-service"
            class="flex.messaging.services.RemotingService"
            messageTypes="flex.messaging.messages.RemotingMessage">
            <destination id="MyBusinessService">
                <channels>
                    <channel ref="my-graniteamf" />
                </channels>
                <properties>
                    <factory>springFactory</factory>
                    <source>myBusinessService</source>
                </properties>
            </destination>
            </destination>
        </service>
        <service id="messaging-service"
            class="flex.messaging.services.MessagingService"
            messageTypes="flex.messaging.messages.AsyncMessage">
            <adapters>
                <adapter-definition id="default" class="org.granite.gravity.adapters.SimpleServiceAdapter" default="true"/>
            </adapters>
            <destination id="gravity">
                <channels>
                    <channel ref="my-gravityamf"/>
                </channels>
            </destination>
        </service>
    </services>
    <channels>
        <channel-definition id="my-gravityamf" class="org.granite.gravity.channels.GravityChannel">
            <endpoint
                uri="http://{server.name}:8080/gravity/amf"
                class="flex.messaging.endpoints.AMFEndpoint"/>
        </channel-definition>
        <channel-definition id="my-graniteamf"
            class="mx.messaging.channels.AMFChannel">
            <endpoint
                uri="http://{server.name}:8080/graniteamf/amf"
                class="flex.messaging.endpoints.AMFEndpoint" />
        </channel-definition>
    </channels>
</services-config>

谢谢

编辑:由IntelliJ运行的命令:

Information:[debug (module MyModuleFlex)]: C:Program FilesJetBrainsIntelliJ IDEA 2019.1.3jbrinjava.exe -Dapplication.home=C:Productsflex_sdk_3.2.0.3958+AdvancedDataGrid -Xmx384m -Dsun.io.useCanonCaches=false -Dfile.encoding=UTF-8 -Djava.awt.headless=true -Duser.language=en -Duser.region=en -Xmx2048m -classpath C:Program FilesJetBrainsIntelliJ IDEA 2019.1.3pluginsflexlibidea-flex-compiler-fix.jar;C:Productsflex_sdk_3.2.0.3958+AdvancedDataGridlibcompc.jar flex2.tools.Compiler -load-config=C:Usersme.IntelliJIdea2019.2systemcompile-serverflex_4ed7173f\_temp_IntelliJ_IDEAidea-180AF0C3-379BE322.xml -load-config=C:WorkspacesFlexMyModuleFlexflex-config.xml
答案

我有完全相同的问题。您有解决方案吗?

以上是关于Granite数据服务:错误:[debug(模块MyModuleFlex)]:无法创建解析器来加载消息传递配置的主要内容,如果未能解决你的问题,请参考以下文章

常用模块

logging 模块

python logging模块详解[转]

python之logging模块

ansible debug模块学习笔记

ansible debug模块学习笔记