function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
DCSDCS 

External web service integration

I need to call  an external service from VF. I am trying to generate apex classes from WSDL and running into issues for import and includes as shown below.

 

Failed to parse wsdl: Unknown element: import

Failed to parse wsdl: Found schema import from location CLiteratureItems.xsd. External schema import not supported

Failed to parse wsdl: Unsupported Schema element found http://www.w3.org/2001/XMLSchema:include. At: 7:57

 

I have seen some posts on these and suggestion is to rework on the wsdl to bring in the external wsdl's into the same. 

 

Is there any documentation on how to get this resolved. 

 

Really appreciate your help.

Message Edited by DCS on 04-23-2009 01:55 PM
dgrigsbydgrigsby

DCS,

 

I just went down this journey recently, and yes there are lots of "clean up" items.

 

I have done a large post on the subject. Please review and comment on as appropriate.

 

 
or
 

 

1. WSDL - I would highly suggest using a WSDL/XML tool like Atlova XMLSpy (free trial) to examine the Types that are imported. It will allow you to trim down, and integrate the imported (manually - wish they had a merge - going to post that feature request at Atlova) xsd types, etc. I normally work with Visual Studio or Eclipse and they just couldn't get there. It will show you what is in the namespace and what is imported in the WDSL tab visually by color coding.

 

      a. WSDL Apex Class creation Limitations

          -Size of final Apex Class - 100K characters
        -Size of WSDL input - 1Meg
          - No Imports and no implied types from defined named spaces if they contain definitions (xsd which ws-security does).
           -No Attributes (xsd which ws-security does).
           -No annotations (xsd which ws-security does).

           -No multipe bindings (which most do 1 and 12)

 

2. Be prepared to spend some time (read as parse, fix error, rise and repeat) many times

3. Best SF reference I found was Link:

4. In the end, you may find to get it working that the HTTP request and manual soap xml codeup to be the quickest solution to get it running, Twitter and Facebook integrations work this way. It was really faster in the end for me.

 

Best Regards,

 

 

David W. Grigsby
Grigsby Consulting LLC
Intellectual Capital for Your Business
484 East Carmel Drive Suite 390
Carmel, IN 46032
 
 

 

Message Edited by dgrigsby on 04-28-2009 03:36 PM
sornasorna

Hi,

I have a requirement for dow jones factiva integration with salesforce and I am new to this Wsdl and xml. I am facing the same problem with this import element. So, could you please let me know about the steps to generate a apex class from the factiva wsdls?

 

Or is there any other way to integrate with factiva, like through HTTP requests and responses?

 

 

Thanks in advance,

Sorna

othmaneothmane

dgrigsby wrote:

DCS,

 

I just went down this journey recently, and yes there are lots of "clean up" items.

 

I have done a large post on the subject. Please review and comment on as appropriate.

 

 
or
 

 

1. WSDL - I would highly suggest using a WSDL/XML tool like Atlova XMLSpy (free trial) to examine the Types that are imported. It will allow you to trim down, and integrate the imported (manually - wish they had a merge - going to post that feature request at Atlova) xsd types, etc. I normally work with Visual Studio or Eclipse and they just couldn't get there. It will show you what is in the namespace and what is imported in the WDSL tab visually by color coding.

 

      a. WSDL Apex Class creation Limitations

          -Size of final Apex Class - 100K characters
        -Size of WSDL input - 1Meg
          - No Imports and no implied types from defined named spaces if they contain definitions (xsd which ws-security does).
           -No Attributes (xsd which ws-security does).
           -No annotations (xsd which ws-security does).

           -No multipe bindings (which most do 1 and 12)

 

2. Be prepared to spend some time (read as parse, fix error, rise and repeat) many times

3. Best SF reference I found was Link:

4. In the end, you may find to get it working that the HTTP request and manual soap xml codeup to be the quickest solution to get it running, Twitter and Facebook integrations work this way. It was really faster in the end for me.

 

Best Regards,

 

 

David W. Grigsby
Grigsby Consulting LLC
Intellectual Capital for Your Business
484 East Carmel Drive Suite 390
Carmel, IN 46032
 
 

 

 

Message Edited by dgrigsby on 04-28-2009 03:36 PM

Hello ,

i have the same problems and remarks you stated in your blog post.

can i ask you to share your Apex code that sends manual SOAP messages ?

Also i have this wsdl file that SF can't parse. would you be able to help me edit this wsdl file so it can pass the wsdl2apex process?

 the jbilling.wsdl file is shared in gdocs at this link: https://docs.google.com/open?id=0ByfoCNegjN7zZFUtZkZCZEJBU0U

the referenced IWebServicesSessionBean.wsdl file is at link : https://docs.google.com/open?id=0ByfoCNegjN7zRUFoRG1Sc05SVWs

 

thanks for you time & help.