I wanted to close the loop on this issue, so here's what I was able to do in order to get my Notes app. connected to a hosted app. outside the firewall via a web services client. I opened a ticket with IBM on this but other than letting me know they are aware of the limitation and that they will tag the issue so it gets a bit more attention, they weren't very helpful. (BTY, they followed up on my dissatisfaction, so they are at least paying attention.)
Because the only work-around for this "Name too long" issue with the variable names in the LotusScript version of the web services consumer is a Java web services consumer, I had to crack open Apache Axis and find out what goes into a Java web services consumer. Turns out, after you get your bearings it's actually a pretty powerful package once you get to know it. DDE is a blessing in this regard because you have access to all the classes that Axis generates. (It also doesn't hurt that Axis is a widely implemented project and there are plenty of examples if you Google them.)
After creating the new web service consumer by importing the WSDL, I created the Java agent and imported the web services consumer as a library. I then used an import statement to reference the %Soap class and the %Locator class AXIS generated for me (substitute your WSDL-specific names for my %). In my agent I instantiate a new %Soap object by calling the getSoap method of the %Locator. I then use the setCredentials method to pass my ID and password to the service. Finally, I call the web service method I want, pass the parameters and chain on the get% (getResponse for my method) method to fill a variable for use further on in my agent.
As for the SSL piece, it was simply a matter of importing the remote site's certificate to the server's keyring file and making sure the keyring file was available to http (on Internet Ports tab of the Ports tab on the Server Doc). They had a GoDaddy CA so my server didn't know how to negotiate SSL.
Saturday, February 19, 2011
Subscribe to:
Post Comments (Atom)
2 comments:
The name too long problem exists since Notes 7 (so more than 5 years). I don't think they will ever fix it (for Lotusscript).
True, however, in 7 it was just web services you created from Notes agents. If you ran into variable name lengths too long, you could handle that yourself. Now with web service consumers (especially outside the firewall) variable names are mostly outside your control.
It would be nice if Lotus spelled this out somewhere in the documentation (I couldn't find any reference to it, at least).
Post a Comment