Watch videos with subtitles in your language, upload your videos, create your own subtitles! Click here to learn more on "how to Dotsub"

Invoke LiveCycle Data Services via SOAP

0 (0 Likes / 0 Dislikes)
[Adobe Developer Connection] [Duane Nickull - Platform Evangelist] Hello, I'm Billy Idol. No, actually, I'm not. I'm Duane Nickull. I'm an Adobe Evangelist. But today we're going to work with LiveCycle ES2, instead of singing a song like White Wedding. We've done some initial setup for our developer environment in the previous episode of this series. And in this series, we're going to continue on some of the concepts, so we set up the default EJB SDK client, and we made a call to LiveCycle ES server. Now, I have the server still up and running on my laptop and we're going to change it now because we run into a problem sometimes when we have to make calls over a corporate firewall that the JMP protocol starts to disintegrate or not get through, based on how the firewalls are configured. And a lot of people have moved to a synchronous messaging SOAP service, and this provides a very, very robust transport layer with a lot of extra features. So in order to take our previous sample and convert it to work with SOAP, it's very, very simple. Just to get started, I'll just review the code that we wrote in the first one, and then we'll see where the changes had to been made. So here is my project. I've set it up with the connection properties, and in this case, I've made a lot of imports. I've imported all of the Adobe LiveCycle client side, SDKs. The jar files are in my project folder. I have a lot of them. And we've set up the service client factory properties to use the EJB endpoint, a JNP 1099, and when we make a call, it takes a document from this particular path, and it will convert it to a PDFA document and dump it back in this path here. So if you run that, it works really well. I'm on the same machine, the local host. So this doesn't really have any problem getting through, and we can get a result and see the document that is being created. Now, the problem comes when you start to go to an environment where you have to cross corporate firewalls or when you have to get to a remote endpoint that's not within your domain. And this is where you may want to move to the SOAP protocol. So luckily, changing this to work on SOAP is very, very easy. I'll show you how. We just delete this line of code here. I'll make this a little bit larger, so we can see what's going on. The code complete guide is here, so we're going to save. Instead of using the service client EJB_ENDPOINT, we're going to pick the SOAP_ENDPOINT. And the SOAP_ENDPOINT is going to have to have the URL. And in this case, it's "http://localhost: --instead of port 1099, this now runs on port 8080. Our next one, we've got the DSC_TRANSPORT_PROTOCOL set. Now, in this case, we're using the EJB_PROTOCOL, and we're going to go back and set that to the SOAP_PROTOCOL and there it is in our code complete. And the server type is the same, and our USERNAME and PASSWORD can remain exactly as they are. We'll just save this. And shrink it down, and we'll give this a run. And it has returned the document. Let's run that again, and just give it a different name than the adc1 document, so we'll call it adc2 and run that again. Now, this time it runs a little bit faster, and we have our adc2.pdfa document. And you can see right that it says, "You are viewing this document in PDF/A mode. So thanks to the work of Scott McDonald and Tyler Rushdon and some of the other celebrities over on the LiveCycle ES2 team, this stuff is really easy to use. So if you're a Java developer, you're a little bit curious about LiveCycle ES, download it, contact us here at the show. We can get you a developer license DVD out there and point you at all of these code samples. And with these videos, you'll be able to be up and running in no time. Thank you. [rocket noise]

Video Details

Duration: 4 minutes and 33 seconds
Country:
Language: English
License: All rights reserved
Genre: None
Views: 84
Posted by: adobetv on Oct 21, 2010

Join Platform Evangelist Duane Nickull as he further explores how a Java developer can work with LiveCycle Data Services and LC Enterprise Suite 2.

Caption and Translate

    Sign In/Register for Dotsub to translate this video.