After never needing it for 20 years, I now need to develop and implement a SOAP solution which will send claim information out to a site, and return responses.
I'm RTFM-ing now, but one thing that concerns me, is that if I understand this correctly, I need a web server to get responses back. Is this correct?
We have a MS database server where the data, and this application would live. We have a separate web server, on a linux box, that can access the MS machine.
If I write this, 1) can I send this request out from the DB Server, and get a response back? 2) Send something to the web server, have the server send and receive the request and send it back to the db server? 3) run a very limited web server which would only listen for the client's ip range, in order to send/get requests?
I'm not looking for details, I just need an idea of the general direction I need to head. If I could do 1) that would be awesome, but if I'm understanding what I'm reading so far, I'll need to do 2 or 3.
Would appreciate clues. Thank you!
On Mon, Mar 21, 2016 at 9:43 AM, Vince Teachout vince@recordables.com wrote:
After never needing it for 20 years, I now need to develop and implement a SOAP solution which will send claim information out to a site, and return responses.
My condolences.
I'm RTFM-ing now, but one thing that concerns me, is that if I understand this correctly, I need a web server to get responses back. Is this correct?
Nope. SOAP is just an API for sending and receiving packets of data over the internet. Depending on how the services are set up, you should be able to "consume" (send data and get responses) from a web service set up by the other party (who likely has a web server to do this) with a FoxPro app.
It is possible to configure a VFP app with appropriate web server software to act as the server in this case, but you'll need to look at the documentation supplied by the vendor to determine what services they offer and what they expect you to provide.
Which FMs are you reading? Rick Strahl's west-wind.com site has some of the best references. There's also some good stuff on the Fox Wiki, and in the archives here.
On 3/21/2016 10:05 AM, Ted Roche wrote:
I'm RTFM-ing now, but one thing that concerns me, is that if I understand this correctly, I need a web server to get responses back. Is this correct?
Nope. SOAP is just an API for sending and receiving packets of data over the internet. Depending on how the services are set up, you should be able to "consume" (send data and get responses) from a web service set up by the other party (who likely has a web server to do this) with a FoxPro app.
So I should be able to do this from my MS Server, which is not running a web server, purely in VFP? This gives me hope! :-)
Which FMs are you reading? Rick Strahl's west-wind.com site has some of the best references. There's also some good stuff on the Fox Wiki, and in the archives here.
We purchased and installed WestWind client, precisely because it has soap and xml classes in it. Started RTFM, but got hung up with something, decided to take a break, and read the older MS "walkthrough" That's when I started to get concerned. I think I'll switch back to Strahl's and more recent documentation. Thanks!
My guess is that you need to deal with their web service? "a SOAP solution which will send claim information out to a site"
They will post back to your web service as well? "and return responses."
You have a Web presence already. "We have a separate web server, on a linux box, that can access the MS machine."
Just put up a web service on that web server to push to them as needed as well as wrote the reply you get back from them. Sounded easy right? Not necessarily the reality in the end. Basically you are going to send out an XML message for them to process. Expect to have a security layer or two as protection for you and them that need to be confirmed before you pass that XML message of the claim.
When they respond back you have to have the security set as well and then receive the xml from them, parse it and do what needs to be done depending on your logic.
On Mon, Mar 21, 2016 at 8:43 AM, Vince Teachout vince@recordables.com wrote:
After never needing it for 20 years, I now need to develop and implement a SOAP solution which will send claim information out to a site, and return responses.
I'm RTFM-ing now, but one thing that concerns me, is that if I understand this correctly, I need a web server to get responses back. Is this correct?
We have a MS database server where the data, and this application would live. We have a separate web server, on a linux box, that can access the MS machine.
If I write this,
- can I send this request out from the DB Server, and get a response back?
- Send something to the web server, have the server send and receive the
request and send it back to the db server? 3) run a very limited web server which would only listen for the client's ip range, in order to send/get requests?
I'm not looking for details, I just need an idea of the general direction I need to head. If I could do 1) that would be awesome, but if I'm understanding what I'm reading so far, I'll need to do 2 or 3.
Would appreciate clues. Thank you!
--
Vince Teachout Senior Analyst Recordables, Inc. 312-288-8566
-----BEGIN PGP PUBLIC KEY BLOCK----- Version: GnuPG v2
mQENBE2o8OkBCADeegwZu8ZeYxoAwuTLcl1rEXT2fovoCSSHjyAUBrcezJDttLh7 pMCYVdwvwPesnaA4M05gv1VPhlgg+tjkyBxiqhZja7URMNasDvmzIyzFrh6Eedpf Vn8zf5SEzpi6PQuI4KKEvexL7eTilPtnB+lJmaVVDxDI1rUk6jsHAJ1FDAZDnRab PZfWt6woLhzIv3obq07dp1fnRr9CPG5OVjUfzUwLYcCy6eUw6555vnwnHeZG+W6c mAZEV0082sk00NcSz1FoE8hA+ULZjkRiIBhU7viLJ12Tpw5VcsCM6UjooOds7OhQ 3wYDYwBPy7WC9eH/3A3RGuZ8pfc0AT7e//FjABEBAAG0NVZpbmNlIFRlYWNob3V0 ICgyMDExMDQxNS1mb3Rzb3RhKSA8dmluY2VAY2FyYWNhbC5uZXQ+iQE4BBMBAgAi BQJNqPDpAhsPBgsJCAcDAgYVCAIJCgsEFgIDAQIeAQIXgAAKCRCpaAY+vVSIgxjt B/0UPUl6ejbu0w1zhCfAVjqckKZoLbFqN7GUjPhKRpb3Fof5chzbI8/RYjgSiJF2 dXjKOH4xyXTDQ1M7zucjLC+3GNLb1y9N803z5FMA6pTtj3ySYPhY+r4yl6TiZDs8 8Re+hRA3e06gTy1N4oF24LgDckf78DPWMeqqKjowT623Ttvs1QBTCj3OIvbW2X+i XJWalOaKFCSUPaZX6zBaUDBT3fZ0sLnAUtDF0m7i1R7HKVI0RHyHWYlQURvV0glQ 1JSLGEsiHhWyetfbnz0hk4dZ/25S0WU+Mwq4CdEAluj6EdPCG4DurlB7TQogzZJ+ 8sqPYq1pQ5WTnsYQU5yIUHUm =LHkH -----END PGP PUBLIC KEY BLOCK-----
[excessive quoting removed by server]
On 3/21/2016 10:06 AM, Stephen Russell wrote:
My guess is that you need to deal with their web service? "a SOAP solution which will send claim information out to a site"
They will post back to your web service as well? "and return responses."
Correct.
You have a Web presence already. "We have a separate web server, on a linux box, that can access the MS machine."
Just put up a web service on that web server to push to them as needed as well as wrote the reply you get back from them.
That was my understanding, and my concern is I don't have any tools to write a web service for a Linux box. (Unless a web-service is something that's agnostic, and I can write it on my vfp machine, and then have it run on the LAMP machine?)
If I'm understanding Ted's response correctly, though, I can do both send and receive from a VFP program on the MS server, which would be perfect for me. Thanks!
You have to read the requirements from this other business in particular the reply message. Will they send it to you and you have to receive, catch it at any time? Or is it an automatic return from the soap message you initially send?
I have done a few service apps and they are a lot of work as they start to grow in capability.
Heads up on the communication with their service. In some cases after you pass security checks they will send you an empty document, xml object in reality that is schema. You have to put in the correct settings and pass it back for them to get to the step you want to be at, submission of your soap message.
I had to interact with local county service for court data. After security they would send a what type of data are you interested in form. My situation was always pulling data for local consumption instead of uploading data. You may have it a lot easier.
On Mon, Mar 21, 2016 at 9:25 AM, Vince Teachout teachv@taconic.net wrote:
On 3/21/2016 10:06 AM, Stephen Russell wrote:
My guess is that you need to deal with their web service? "a SOAP solution which will send claim information out to a site"
They will post back to your web service as well? "and return responses."
Correct.
You have a Web presence already. "We have a separate web server, on a
linux box, that can access the MS machine."
Just put up a web service on that web server to push to them as needed as
well as wrote the reply you get back from them.
That was my understanding, and my concern is I don't have any tools to write a web service for a Linux box. (Unless a web-service is something that's agnostic, and I can write it on my vfp machine, and then have it run on the LAMP machine?)
If I'm understanding Ted's response correctly, though, I can do both send and receive from a VFP program on the MS server, which would be perfect for me. Thanks!
[excessive quoting removed by server]
Vince Teachout wrote on 2016-03-21:
On 3/21/2016 10:06 AM, Stephen Russell wrote: My guess is that you need to deal with their web service? "a SOAP solution which will send claim information out to a site"
They will post back to your web service as well? "and return
responses."
Correct.
You have a Web presence already. "We have a separate web server, on a linux box, that can access the MS machine."
Just put up a web service on that web server to push to them as needed as well as wrote the reply you get back from them.
That was my understanding, and my concern is I don't have any tools to write a web service for a Linux box. (Unless a web-service is something that's agnostic, and I can write it on my vfp machine, and then have it run on the LAMP machine?)
If I'm understanding Ted's response correctly, though, I can do both send and receive from a VFP program on the MS server, which would be perfect for me. Thanks!
Vince,
VFP is not multi-threaded, don't expect it to be a service that responds to multiple clients. Something needs to instantiate multiple instances of VFP to do that. (VFP being an ISAPI control in IIS. VFP COM in a C# WCF project.)
There are multiple ways to do SOAP. I understand Rick Strahl has created a good framework for this. I used the tools provided with VFP to build an internal project. It was a challenge to debug.
Tracy Pearson PowerChurch Software
On 3/21/2016 10:57 AM, Tracy Pearson wrote:
VFP is not multi-threaded, don't expect it to be a service that responds to multiple clients. Something needs to instantiate multiple instances of VFP to do that. (VFP being an ISAPI control in IIS. VFP COM in a C# WCF project.)
No, this will be a single client that will send out a user-initiated request to a web service URL, and wait for a response. It will time out after some X seconds, but that's not supposed to happen. (haha) So that doesn't sound like an issue.
The other thing would be when it does time out, their server will hold responses in a queue, and I would want to be able to send a request to the queue and handle responses. Again, a single request. So I think I'm good, there.
There are multiple ways to do SOAP. I understand Rick Strahl has created a good framework for this.
I'm glad I got that framework then! Thanks!
On Mon, Mar 21, 2016 at 10:25 AM, Vince Teachout teachv@taconic.net wrote:
If I'm understanding Ted's response correctly, though, I can do both send and receive from a VFP program on the MS server, which would be perfect for me. Thanks!
Well, what you know when you say "the vendor uses SOAP" isn't much more than saying "the vendor uses electricity -- can I do that from VFP?" The answer is "Yeah, but..."
Simple Object Access Protocol is MS's "me, too!" answer to low-level messaging on the internet. In simple form, you send a properly formatted "What's up?" to a SOAP API on a server, and it says "Wazzup!" back to you. Of course, from there, it gets way more complex: there's authorization/login, authentication, properly formatting your request and decrypting their response, there's WSDL as a sort of web service description language, and of course there are incompatible versions of SOAP 1.0, 2.0, 3.0 and 4.0. And almost no one actually implements everything to the spec, so there's always some adjustment to get things working right.
But the basic answer is that "FoxPro can do SOAP."
On 3/21/2016 11:01 AM, Ted Roche wrote:
But the basic answer is that "FoxPro can do SOAP."
What I'm understanding from the responses is: 1)You can do it, 2)you DON'T need a web server, 3)and it will be hard work.
1) I was pretty sure of to begin with 2) Is what I was worried about, and it seems like I'm good to go without a web server 3) Doesn't scare me, especially as it's billable! :-)
Thanks, all!
"billable"
Ah, music to my ears!
On Mon, Mar 21, 2016 at 11:26 AM, Vince Teachout teachv@taconic.net wrote:
On 3/21/2016 11:01 AM, Ted Roche wrote:
But the basic answer is that "FoxPro can do SOAP."
What I'm understanding from the responses is: 1)You can do it, 2)you DON'T need a web server, 3)and it will be hard work.
- I was pretty sure of to begin with
- Is what I was worried about, and it seems like I'm good to go without a
web server 3) Doesn't scare me, especially as it's billable! :-)
Thanks, all!
[excessive quoting removed by server]
Well, finally got deep into the documentation provided by the vendor:
"Testing Data – Field and relationship validation will be performed. Fields will be checked for accuracy and completeness as well as compared to other relational fields...
*The Response will be sent to the customer’s incoming post-back URL when the system is ready (usually within minutes).*
The <MsgStatus> will indicate whether the Request resulted in a 'Success” or was “Rejected.'"
That sounds pretty clearly to me that I'll have to have a web service running on a web server. :-(
Vince Teachout wrote on 2016-03-21:
Well, finally got deep into the documentation provided by the vendor:
"Testing Data - Field and relationship validation will be performed. Fields will be checked for accuracy and completeness as well as compared to other relational fields...
*The Response will be sent to the customer's incoming post-back URL when the system is ready (usually within minutes).* The <MsgStatus> will indicate whether the Request resulted in a 'Success" or was "Rejected.'"
That sounds pretty clearly to me that I'll have to have a web service running on a web server. :-(
Vince,
I agree with your understanding of those words.
What do you need to do you with the information in the callback? A C# WebAPI self-hosted project could be setup to handle it. A php or python project could be setup as well.
Tracy Pearson PowerChurch Software
On 3/21/2016 2:20 PM, Tracy Pearson wrote:
I agree with your understanding of those words.
What do you need to do you with the information in the callback? A C# WebAPI self-hosted project could be setup to handle it. A php or python project could be setup as well.
I just need to get the returning xml data to the database server, parse it, and apply to the data set.
Now that a web server is definitely involved, it actually becomes simpler. I should still be able to push the initial request from VFP as before and get the initial "rejected/pending" response back.
Our web guy can write the PHP "listener" on our separate web server, and anything that comes back will be dumped to a table in a database on our data server. (The web server already has working access to the data server, so that's not a problem)
I'd modify the program to set a flag if a request was sent, then start a timer to check the database if the flag is set.
The other option, if we find it easier, is to dust off the old WAMP server that used to run the website, and is still on the data server, set it to only accept data from the one IP address, and just run the listener on that.
In any event, I think things just got a little easier. :-)
caveat - I have never got SOAP to work - but it's easy to get VFP to consume xml from a website/ URL - e.g. try this:
LOCAL cURL, oHttp as xmlhttp cURL = "http://www.hawthorn-cottage.com/tryText.asp" oHttp = createobject("Microsoft.XmlHttp") oHttp.Open("POST", cURL, .F.) && Synchronous oHttp.Send("") ?oHttp.ResponseText LOCAL oDom as xmldom oDom = CREATEOBJECT("Microsoft.xmldom") && ?? oDom = oHttp.responseXML && ?? ?oDom.baseName && '' ?oDom.nodeName && 'document' RELEASE ALL CLEAR ALL
On 22/03/2016 00:23, Vince Teachout wrote:
... I just need to get the returning xml data to the database server, parse it, and apply to the data set.
<snip>