我刚刚开始使用axis2c (LinuxRev1.5),我重写了一个简单的服务,它是数学服务的add功能的一个副本。
看起来一切正常,但在过程结束时,当服务应该返回和的结果时,它会报告错误“不存在操作”。
我调用了我的服务"ctictrlintf“,在ctictrlintf_invoke函数中,我得到了要添加2参数的节点。
在这里,使用axiom_node_to_string api打印节点的内容。
<ns1:test1 xmlns:ns1="http://ws.apache.org/axis2/services/ctictrlintf">
<param1>40</param1>
<param2>8</param2>
</ns1:test1>在函数的末尾,ctictrlintf_invoke与成瘾的结果相对应。
<ns1:result xmlns:ns1="http://axis2/test/namespace1">48</ns1:result>在此之后发生的情况报告如下。
在addr_out_handler.c中的某个地方,程序报告了错误“无动作存在”,并中止了操作。
[debug] phase.c(210) Invoke the handler AddressingOutHandler within the phase MessageOut
[info] Starting addressing out handler
[debug] addr_out_handler.c(133) No action present. Stop processing addressing
[info] Request served in 0.012 seconds什么是这个错误,需要什么操作才能完成它的工作?
最好的战利品,恩佐
添加18.07.2013 16:56
在config文件axis2.xml中,仍然启用寻址模块
<!-- ================================================= -->
<!-- Global Modules -->
<!-- ================================================= -->
<module ref="addressing"/>当服务器启动时,日志报告会注意到寻址的激活。
[debug] conf_builder.c(234) No custom dispatching order found. Continue with the default dispatching order
[debug] conf_builder.c(379) Module addressing found in axis2.xml
[debug] class_loader.c(140) /usr/local/axis2c/lib/libaxis2_http_sender.so shared lib loaded successfully
[debug] class_loader.c(140) /usr/local/axis2c/lib/libaxis2_http_receiver.so shared lib loaded successfully
[debug] dep_engine.c(1283) axis2_dep_engine_load_module_dll: DLL path is : /usr/local/axis2c/modules/addressing/libaxis2_mod_addr.so
[debug] class_loader.c(140) /usr/local/axis2c/modules/addressing/libaxis2_mod_addr.so shared lib loaded successfully
[debug] dep_engine.c(1283) axis2_dep_engine_load_module_dll: DLL path is : /usr/local/axis2c/modules/logging/libaxis2_mod_log.so
[debug] class_loader.c(140) /usr/local/axis2c/modules/logging/libaxis2_mod_log.so shared lib loaded successfully
[debug] svc_builder.c(318) DLL path is : /usr/local/axis2c/services/ctictrlintf/libctictrlintf.so
[debug] svc_builder.c(318) DLL path is : /usr/local/axis2c/services/echo/libecho.so
[debug] svc_builder.c(318) DLL path is : /usr/local/axis2c/services/math/libmath.so
[debug] phase_holder.c(139) Add handler AddressingInHandler to phase Transport服务代码已经有了以下调用
/* Create EPR with given address */
endpoint_ref = axis2_endpoint_ref_create(env, address);
/* Setup options */
options = axis2_options_create(env);
axis2_options_set_to(options, env, endpoint_ref);
axis2_options_set_action(options, env, "http://www.aesys.com/axis2/services/ctictrlintf/test1");
/* Set service client options */
axis2_svc_client_set_options(svc_client, env, options);
/* Engage addressing module */
axis2_svc_client_engage_module(svc_client, env, AXIS2_MODULE_ADDRESSING);发布于 2013-07-18 10:08:35
此消息是通过寻址模块生成的,这不是一个错误。
您的服务没有寻址支持,也没有发送或接收任何特定于寻址的标头。
关于Axis2 2/C中WS-寻址支持的信息是这里。
https://stackoverflow.com/questions/17720152
复制相似问题