如何通过像 Fiddler 这样的代理使用 intellij/grails 和 wslite soap 客户端来查看消息?

How to use intellij/grails and wslite soap client through a proxy like Fiddler to see the messages?

我想设置一个代理检查工具,例如 fiddler 或 Charles 代理(我都有),这样我就可以看到发送和接收的内容 - 没有这个你就瞎了。

问题是,如何让 grails 2.4.4 或 wslite-0.7.2.0 插件使用我的本地代理服务器?

可悲的是,该插件只有 1 页文档,其中的示例与它应该引入的 groovy-wslite 库完全不同。

例如https://github.com/jwagenleitner/groovy-wslite

说我应该可以做到:

 def proxy = new Proxy(Proxy.Type.HTTP, new InetSocketAddress('proxy.example.com', 8080))
 def client = new SOAPClient("https://www.example.com/ExampleService")
 def response = client.send(proxy:proxy) {

但是当我尝试这种格式时,我得到:

 No signature of method: wslite.soap.SOAPClient.send() is applicable for argument types: (java.net.Proxy, 

找到答案。

        def client = new SOAPClient('https://bla')
        def proxy = new Proxy(Proxy.Type.HTTP, new InetSocketAddress('localhost', 8888))
        client.httpClient.proxy = proxy

        def response = client.send(SOAPAction: 'blabla') {