I am trying to consume a SOAP web service into a cocoa application. The return value which is printing in the log is an HTML error page.
My Main objective is to pass two parameters to the web service and get a value in response. Can anyone please suggest correct way of achieving this?
It could be any number of things. For startes: you may be hitting the wrong URL, you may be sending invalid data and the server is not returning a valid error. The best thing to do is check what you are doing against any docs you may have, then contact the person working on the server side of the project for help debugging.
I know that is not a very specific answer, but I don't have a lot to go on. Hope it helps.
Related
I'm doing OAuth2 to integrate Square and my app which uses Parse as its backend.
My issue is that when Square calls the redirect uri, it directs the user to a subdomain I created in Parse with the authorization code appended to the subdomain uri. I need to extract this authorization code from the uri, but do not know how. Parse Cloud Code is needed to do this.
I believe I need to create a Webhook URL in Cloud Code and then extract the data appended to the URL, the base of which is the subdomain URL. Steps outlining the process, code examples and links to helpful documentation would be much appreciated.
Furthermore, once I figure this out, I need to have my web browser jump the user back to the app that brought up Square initially once this redirect URL is called. Not sure how to do this and haven't found things that make sense. Tips, recommendations and links would be appreciated!
Thanks!
I think the best way to go would be create an independent route on the server that handles all your communication with square. I mean something that doesn't have Parse.
You can now still communicate with Parse from this route and make queries but the best thing is to just create a separate route that id devoid of parse.
Because even if you can find a way to implement via triggers or hooks, Parse might not be able to give you a flexible implementation that can be extensible over time.
We have Intermec CK71 mobile devices (WiFi). There will always be a scenario in which the device sends a request (GET, PUT, or POST), then loses connection. What methods can we use to prevent duplicate PUTs or POSTs? How does the client device know whether or not the server processed its request before losing the connection?
I have seen similar posts like this but the marked answer doesn't go into much detail. I'm not even sure where to begin. Should I be looking into caching (ETag, last modified), or some type of handshaking?
The client device has the .Net Compact Framework 3.5 on it and is hitting the server via its Web API 2 endpoints.
If someone can point me to the right direction or offer any suggestions it would be much appreciated. Thanks.
I am not using REST but as far as I read the information there is no easy way to get an acknowledge and avoid duplicate POST.
As with other high level API frameworks you are tied to what the API offers and it looks like the designers did not think about connection aborts.
The easiest way to workaround this seems to use an unique ID with every post and check the server for knowing these UID before re-posting. If the server does not response with OK for an POST, you have to assume the connection has broken or other things went wrong. Then query the server for the UID you posted to know if the pervious POST was succesful before you try another POST with the same data and UID.
Possibly there is some transaction encapsulation available with REST as available for sql server. A 'transaction' protocol would ensure that a POST has been processed succesfully or will be 'rolled' back, if something failed.
Sorry, but I do not know much about REST.
I need to use jmeter with worklight. I followed the IBM knowledge center and could extract the wl instance from init.But when try to use the login function , it is showing unauthorized 401 and the response is not the authstatus required ,instead it is displaying another instance id. Give me suggestion and document for solving this issue.
Without seeing your test script, it is difficult to answer this question.
However, something to look at is:
Is the instance ID the same one in all trials or not?
If it is the same instance ID then you are likely not properly extracting the instance ID.
If is is not the same instance ID, you might have a configuration problem in the HTTP cookie manager in jMeter. It would be better to see the script.
What exactly did follow from the IBM Knowledge Center? Please provide the link.
I am new to the Windows IIS environment, coming from Linux/Apache. At my new job (ASP.NET shop), they don't currently monitor 404s or any other non-200 HTTP response codes so problems with missing images and files from the website or 500 errors don't surface until a customer emails us weeks later.
What do you guys use to monitor, aggregate and display these responses in .NET? In my old job, I had a script attached to the 404 handler that inserted into a database and from there I created a dashboard that grouped and displayed all the 404s so it was easy to see issues with missing files, etc.
Not sure if it's best to handle at the application level or with some log file aggregator.
What is the best practice for doing the same in ASP.NET?
I appreciate any advice on this
Thanks
You may take a look at ELMAH which is specifically designed for this purpose.
I'm having a really hard time trying to find a resource or online tutorial that explicitly walks you through setting up a WF4 workflow activity that can call out to an external web service. All the videos and online samples I've come across simply demonstrate how to consume a web service that's part of your Visual Studio solution, but my situation entails calling out to a web service on a non-Microsoft server.
I have a service reference added to my VS2010 workflow console project for the web service in question, and it's pointing to the WSDL of the external web service. So far, so good (I think). I have a very basic workflow sequence, using a SendAndReceiveReply workflow control to communicate with the external server, and I believe I have the Send piece configured correctly. The ReceiveReplyForSend is giving me trouble, however, and I'm not sure if I have its Content options set up the right way. I'm invoking an operation called FileCheck, which at the moment for testing purposes always returns a value of 1 like this:
<SOAP-ENV:Envelope>
<SOAP-ENV:Body>
<FileCheckResponse>
<FileCheckResult>1</FileCheckResult>
</FileCheckResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
If I try to run this, however, I get the error "Badly formed SOAP message." For what it's worth, my ReceiveReplyForSend has a single parameter set up called FileCheckResult, though I don't know if that's the correct way to get the above value.
I can put a breakpoint at either activity, but I have no idea how to see what the SOAP call looks like at that point. Can someone either give me some workflow Send/Reply debugging tips or point me in the direction of an excellent step-by-step tutorial of how to consume an external web service in WF4?
Update on Feb. 2, 2011: Thanks to Maurice's suggestion, I see exactly what is failing now. The web service call in my workflow is failing because Visual Studio is generating a reference to the wrong namespace in my workflow Send call. Here is the single bit of XML that is wrong in the SOAP message - I'll leave off the rest of the SOAP envelope for succinctness:
<FileCheck xmlns="http://tempuri.org/">
This is what the WCF Test Client generates, which gets a successful message in return:
<FileCheck xmlns="http://someserver.org/test/" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
This is probably a really newbie question, but is there a setting somewhere that I'm overlooking that adjusts the xmlns value? I tried searching for "tempuri" in my project, but it's nowhere to be found, so I bet I'm overlooking a default setting somewhere.
Update on February 8, 2011: Maurice's latest tip did the trick! I needed to add the proper namespace to the ServiceContractName property for my Send workflow activity.
Adding a reference to an external web service is not much harder than one that is part of the same VS2010 solution. Only in this case you need to provide the URL where VS2010 can find the web service WSDL. As the communications mechanism is standard WSDL and SOAP there should not be a problem in calling the other service.
If you want to debug messages the best tool to use is Fiddler. It will let you see messages on the wire and even build request on the fly. If you have an existing client that can work with the service in question you can monitor its messages and compare them with the messages you are sending. Provided the service doesn't use complex and custom data types the WCF Test Client is a good way to check if the service responds with a standard .NET client app.
The SOAP namepsace is part of the ServiceContractName. Use the following syntax
{http://someserver.org/test/}FileService