Giter Club home page Giter Club logo

Comments (14)

sfell avatar sfell commented on August 20, 2024

You have to use the API endpoint version# that matches the WSDL you used,
you can't mix'n'match.

On Thu, Oct 17, 2013 at 12:12 PM, earlofrose [email protected]:

Using the WSC#29, we receive the following error when trying to call the
DescribeSObjectResult ds = ecn.describeSObject(sfObject); and a similar
error when trying to call DescribeLayoutResult layout =
ecn.describeLayout(sfObject, recTypeIds); depending on whether we use the
v25 or v29 endpoint. We were able to work around this issue using the
lax-minoccurs-checking JVM switch. It appears that elements that are not
required (not being sent in responses from salesforce) are mistakenly being
marked as minOccurs = 1, either through it not being specified or being
directly marked as minOccurs = 1.

Exception details:
com.sforce.ws.ConnectionException: Unexpected element. Parser was
expecting element 'urn:enterprise.soap.sforce.com:compactLayoutable' but
found 'urn:enterprise.soap.sforce.com:createable'
at com.sforce.ws.bind.TypeMapper.verifyTag(TypeMapper.java:387)
at com.sforce.ws.bind.TypeMapper.verifyElement(TypeMapper.java:416)
at
com.sforce.soap.enterprise.DescribeSObjectResult.loadFields(DescribeSObjectResult.java:803)
at
com.sforce.soap.enterprise.DescribeSObjectResult.load(DescribeSObjectResult.java:787)
at com.sforce.ws.bind.TypeMapper.readSingle(TypeMapper.java:629)
at com.sforce.ws.bind.TypeMapper.readObject(TypeMapper.java:505)
at
com.sforce.soap.enterprise.DescribeSObjectResponse_element.loadFields(DescribeSObjectResponse_element.java:67)
at
com.sforce.soap.enterprise.DescribeSObjectResponse_element.load(DescribeSObjectResponse_element.java:58)
at com.sforce.ws.bind.TypeMapper.readSingle(TypeMapper.java:629)
at com.sforce.ws.bind.TypeMapper.readObject(TypeMapper.java:505)
at com.sforce.ws.transport.SoapConnection.bind(SoapConnection.java:172)
at com.sforce.ws.transport.SoapConnection.receive(SoapConnection.java:146)
at com.sforce.ws.transport.SoapConnection.send(SoapConnection.java:110)
at
com.sforce.soap.enterprise.EnterpriseConnection.describeSObject(EnterpriseConnection.java:547)
at org.stjude.crm.EventProxy.listSFPickListItems(EventProxy.java:982)
at org.stjude.crm.EventProxy.listSuffixes(EventProxy.java:3686)
at
org.stjude.events.ui.controllers.AbstractControllerBase.getSuffixes(AbstractControllerBase.java:257)


Reply to this email directly or view it on GitHubhttps://github.com//issues/35
.

from wsc.

earlofrose avatar earlofrose commented on August 20, 2024

Thanks for commenting so quickly!

We were only mixing and matching for discovery and testing. Our most recent builds (which include this failure) are failing on DescribeLayoutResult layout = ecn.describeLayout(sfObject, recTypeIds). This was a v29 wsdl, v29 endpoint and used the wsc#29 to build the client.

Thanks,
Josh

from wsc.

earlofrose avatar earlofrose commented on August 20, 2024

Also, I believe this is a problem with the WSDL generation on salesforce.com's side. It's marking things as required (minOccurs = 1 or no minOccurs set, which defaults it to 1 in WSC) that are not being returned in their responses.

from wsc.

superfell avatar superfell commented on August 20, 2024

Can you double check that you're really using the v29 endpoint, as from my quick testing so far with describeSObject, i haven't seen it not return compactLayoutable yet.

IIRC, WSC has an option to do wire logging, which might be helpful.

from wsc.

superfell avatar superfell commented on August 20, 2024

and also which specific sobject you're seeing this with.

from wsc.

earlofrose avatar earlofrose commented on August 20, 2024

describeSObject works with v29. describeLayout is what fails with v29. Here's the exception, relevant portion of the wsdl and the a piece of the response showing the lack of iconURL.

EXCEPTION
Exception in thread "main" com.sforce.ws.ConnectionException: Unexpected element. Parser was expecting element 'urn:enterprise.soap.sforce.com:iconUrl' but found 'urn:enterprise.soap.sforce.com:label'
at com.sforce.ws.bind.TypeMapper.verifyTag(TypeMapper.java:387)
at com.sforce.ws.bind.TypeMapper.verifyElement(TypeMapper.java:416)
at com.sforce.soap.enterprise.DescribeQuickActionListItemResult.loadFields(DescribeQuickActionListItemResult.java:212)
at com.sforce.soap.enterprise.DescribeQuickActionListItemResult.load(DescribeQuickActionListItemResult.java:201)
at com.sforce.ws.bind.TypeMapper.readSingle(TypeMapper.java:629)
at com.sforce.ws.bind.TypeMapper.readArray(TypeMapper.java:529)
at com.sforce.ws.bind.TypeMapper.readObject(TypeMapper.java:507)
at com.sforce.soap.enterprise.DescribeQuickActionListResult.loadFields(DescribeQuickActionListResult.java:62)
at com.sforce.soap.enterprise.DescribeQuickActionListResult.load(DescribeQuickActionListResult.java:54)
at com.sforce.ws.bind.TypeMapper.readSingle(TypeMapper.java:629)
at com.sforce.ws.bind.TypeMapper.readObject(TypeMapper.java:505)
at com.sforce.soap.enterprise.DescribeLayout.loadFields(DescribeLayout.java:229)
at com.sforce.soap.enterprise.DescribeLayout.load(DescribeLayout.java:201)
at com.sforce.ws.bind.TypeMapper.readSingle(TypeMapper.java:629)
at com.sforce.ws.bind.TypeMapper.readArray(TypeMapper.java:529)
at com.sforce.ws.bind.TypeMapper.readObject(TypeMapper.java:507)
at com.sforce.soap.enterprise.DescribeLayoutResult.loadFields(DescribeLayoutResult.java:108)
at com.sforce.soap.enterprise.DescribeLayoutResult.load(DescribeLayoutResult.java:100)
at com.sforce.ws.bind.TypeMapper.readSingle(TypeMapper.java:629)
at com.sforce.ws.bind.TypeMapper.readObject(TypeMapper.java:505)
at com.sforce.soap.enterprise.DescribeLayoutResponse_element.loadFields(DescribeLayoutResponse_element.java:62)
at com.sforce.soap.enterprise.DescribeLayoutResponse_element.load(DescribeLayoutResponse_element.java:54)
at com.sforce.ws.bind.TypeMapper.readSingle(TypeMapper.java:629)
at com.sforce.ws.bind.TypeMapper.readObject(TypeMapper.java:505)
at com.sforce.ws.transport.SoapConnection.bind(SoapConnection.java:207)
at com.sforce.ws.transport.SoapConnection.receive(SoapConnection.java:181)
at com.sforce.ws.transport.SoapConnection.send(SoapConnection.java:99)
at com.sforce.soap.enterprise.EnterpriseConnection.describeLayout(EnterpriseConnection.java:1051)
at org.stjude.crm.Main.main(Main.java:176)

RESPONSE



Post

FeedItem.TextPost

Post



File

FeedItem.ContentPost

Post

WSDL




from wsc.

earlofrose avatar earlofrose commented on August 20, 2024

Here's the WSDL and RESPONSE.... markup

WSDL:
<complexType name="DescribeQuickActionListResult">
<sequence>
<element name="quickActionListItems" type="tns:DescribeQuickActionListItemResult" minOccurs="0" maxOccurs="unbounded"/>
</sequence>
</complexType>

<complexType name="DescribeQuickActionListItemResult">
<sequence>
<element name="colors" type="tns:DescribeColor" minOccurs="0" maxOccurs="unbounded"/>
<element name="iconUrl" type="xsd:string" nillable="true"/>
<element name="icons" type="tns:DescribeIcon" minOccurs="0" maxOccurs="unbounded"/>
<element name="label" type="xsd:string"/>
<element name="miniIconUrl" type="xsd:string" />
<element name="quickActionName" type="xsd:string" />
<element name="targetSobjectType" type="xsd:string" nillable="true"/>
<element name="type" type="xsd:string"/>
</sequence>
</complexType>

RESPONSE:
<quickActionList>
<quickActionListItems>
<label>
Post</label>
<quickActionName>
FeedItem.TextPost</quickActionName>
<type>
Post</type>
</quickActionListItems>
<quickActionListItems>
<label>
File</label>
<quickActionName>
FeedItem.ContentPost</quickActionName>
<type>
Post</type>
</quickActionListItems>

from wsc.

superfell avatar superfell commented on August 20, 2024

Thanks, yeah, I'm seeing the same thing.

from wsc.

jefflai avatar jefflai commented on August 20, 2024

I'll follow up with the salesforce team that owns the DescribeQuickAction
feature.

On Thu, Oct 17, 2013 at 2:52 PM, Simon Fell [email protected]:

Thanks, yeah, I'm seeing the same thing.


Reply to this email directly or view it on GitHubhttps://github.com//issues/35#issuecomment-26556276
.

from wsc.

earlofrose avatar earlofrose commented on August 20, 2024

Fantastic! Thanks, guys.

Sent from my iPhone

On Oct 17, 2013, at 5:26 PM, "Jeff Lai" <[email protected]mailto:[email protected]> wrote:

I'll follow up with the salesforce team that owns the DescribeQuickAction
feature.

On Thu, Oct 17, 2013 at 2:52 PM, Simon Fell <[email protected]mailto:[email protected]>wrote:

Thanks, yeah, I'm seeing the same thing.


Reply to this email directly or view it on GitHubhttps://github.com//issues/35#issuecomment-26556276
.


Reply to this email directly or view it on GitHubhttps://github.com//issues/35#issuecomment-26558460.

from wsc.

dwfallin avatar dwfallin commented on August 20, 2024

hey jefflai - can you give any kind of update on this? (has someone accepted it as an issue, maybe started a bug for tracking?)
thanks!

from wsc.

michaelbini avatar michaelbini commented on August 20, 2024

I had the same problem and I fix it by updating the authEndPoint
ConnectorConfig config = new ConnectorConfig();
config.setAuthEndpoint("https://login.salesforce.com/services/Soap/c/29.0/");

hope this will help.

from wsc.

dwfallin avatar dwfallin commented on August 20, 2024

thanks for the suggestion. so, you updated the endpoint by adding a '/'? not sure how that would affect the meta-data thats being returned from the calls? i tried it anyway with same results.

from wsc.

jefflai avatar jefflai commented on August 20, 2024

@earlofrose @dwfallin a patch to fix this issue on the server side was deployed. Please reopen if you are still experiencing this issue

from wsc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.