在freeswitch中使用url获取参数

问题描述 投票:0回答:1

我正在使用Freeswitch,我需要在xml_cdr.conf.xml上打一个网址,比如

<configuration name="xml_cdr.conf" description="XML CDR CURL logger">
  <settings>
    <param name="url" value="http://localhost:8080/ftpTransferPerCall?uuid=${uuid}"/>
  </settings>
....
</configuration>

但它给出了错误,如,

[ERR] mod_xml_cdr.c:395 Got error [400] posting to web server [http://localhost:8080/ftpTransferPerCall?uuid=${uuid}]
[ERR] mod_xml_cdr.c:402 Retry will be with url [http://localhost:8080/ftpTransferPerCall?uuid=${uuid}]
[ERR] mod_xml_cdr.c:418 Unable to post to web server, writing to file

它用/usr/local/freeswitch/log/xml_cdr<uuid_values>.cdr.xml名称写一个文件

我想点击这个网址并在我的控制器中获取它,

@RequestMapping(value ="/ftpTransferPerCall", method = RequestMethod.POST)
public void ftpTransferSingle(@RequestParam(value="uuid", required = false) String uuid)  { 
  System.err.println("In Ftptransfer:- "+uuid);
}

有没有办法点击这个网址作为帖子,并在控制器中得到它,而不是在/usr/local/freeswitch/log/xml_cdr/<uuid_values>.cdr.xml得到下载的文件?

提前致谢。

spring-mvc freeswitch
1个回答
1
投票

地址http://localhost:8080/ftpTransferPerCall当然可以从运行freeswitch的服务器获得吗?

试试curl -x POST http://localhost:8080/ftpTransferPerCall

我的意思是这与freeswitch没有问题。

© www.soinside.com 2019 - 2024. All rights reserved.