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
AlanPerkinsAlanPerkins 

Generating a WSDL from a WebService includes all Enterprise Objects - Problem

I just generated a WSDL for a new Webservice class I created - the first for a month or two. This time the WSDL generated includes 25000 lines of definition for the entire custom object set instead of just the interface to the webservice. This is a big problem.

 

How do I get the WSDL the way it used to be with just the interface to the webservice and why am I getting all the custom object definitions, which should only be included in the Enterprise WSDL?

 

 

Best Answer chosen by Admin (Salesforce Developers) 
AlanPerkinsAlanPerkins

I sorted it out.

 

The Webservice took as a parameter a complex object type rather than generic primitives and lists of primitives. Still strange that it would require all the objects in the enterprise to imported that way - I think that is a design flaw - it should still leave those to the Enterprise WSDL.

 

I have changed my Webservice to only load primitives.

All Answers

AlanPerkinsAlanPerkins

I sorted it out.

 

The Webservice took as a parameter a complex object type rather than generic primitives and lists of primitives. Still strange that it would require all the objects in the enterprise to imported that way - I think that is a design flaw - it should still leave those to the Enterprise WSDL.

 

I have changed my Webservice to only load primitives.

This was selected as the best answer
SuperfellSuperfell
The set of SObject definitions are only included if somewhere in your webservice interface you have a reference to an sobject (either directly as a parameter, or indirectly as a webserviced property of a custom class)