-
Notifications
You must be signed in to change notification settings - Fork 92
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
kdwsdl2cpp doesn't generate necessary headers #254
Comments
The API to use is rather something along the lines of
but the question is indeed why kdwsdl2cpp doesn't generate that. Maybe It sounds like WS/Addressing support isn't fully integrated with kdwsdl2cpp indeed, please let me know if this helps, then we can take a look at improving this integration. The first step will be to extend unittests/ws_addressing_support ... |
Hi, <wsa:Action>
http://www.onvif.org/ver10/events/wsdl/PullPointSubscription/PullMessagesRequest
</wsa:Action> However, that's not the element I needed to add. So, maybe I need to implement a manual call using the API directly instead of using the automatically generated files? Or is there any other solution? Thanks a lot |
so that WS-Addressing support can be used with WSDL-generated services Fixes #254
Please update to latest master, and do
I suppose that the WSDL files contain all the information necessary for kdwsdl2cpp to generate the message addressing properties automatically, but I don't know enough about ws-addressing to implement that (someone else implemented the current support for WS-addressing). Meanwhile, this new method at least allows to set WS-addressing properties manually on WSDL-generated messages. Please let me know how this works for you. |
I've been trying to use the method you propose, but although I've updated to master and build new headers and sources files which contains that method, it does nothing. The sent soap header is empty, there is no addressing information added to it |
That is surprising, given that the unittest I wrote as part of that commit, shows that the addressing information is sent correctly. There must be a difference somewhere. Ah, I found it, after writing a testcase based on the onvif WSDL. The code required a SOAP action to be set in order to write addressing properties. I removed that check now, I hope that's correct (no time to read the WS-Addressing spec). Please git pull and try again. |
It's working now! Thanks a lot! |
If you use the blocking API ( Something like:
|
I suppose we could add a method |
Ok, so I'll use jobs for now, but u think it would be useful to have the lastReply() method you mentioned |
Hello everyone,
I'm working on a project in which I need to use KDSoap to consume a SOAP service. The service is given by this wsdl file.
I have generate the .h and .cpp files and they seem to work fine with most of the methods, but there's one specific (though critical) method which doesn't work.
The method itself is the one named PullMessages. The problem is that the services returns an HTTP 400 respose to the call, and after spending some time with SoapUI and wireshark to check the differences, I have managed to found them. The only thing which prevents the method from working is that KDSoap isn't including any SOAP header, and it needs to include the endpoint url on a header named To, which uses "http://schemas.xmlsoap.org/ws/2004/08/addressing" as a namespace.
To make it clearer, the message currently sent is:
while it should be
Note that on the message that should be used there's a new namespace.
I don't really know why that namespace and header isn't automatically added, as it's mandatory. However, I've also tried to add it manually by adding a header to the KDSoapClientInterface:
In this case, the header is added, but the specified namespace is not used, instead the header is added as a tag "ns1:To". Is this a bug? Or am I doing something wrong? I've been using the documentation and this seems to be the right way to do this, but it isn't working.
Any help would be appreciated.
Thanks a lot.
The text was updated successfully, but these errors were encountered: