You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Carlos Ciatti (Jira)" <ji...@apache.org> on 2021/04/16 17:36:00 UTC
[jira] [Comment Edited] (CAMEL-16516) camel-salesforce - Maven
plugin generated code AbstractDescribedSObjectBase can cause NPE
[ https://issues.apache.org/jira/browse/CAMEL-16516?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17323988#comment-17323988 ]
Carlos Ciatti edited comment on CAMEL-16516 at 4/16/21, 5:35 PM:
-----------------------------------------------------------------
because the template does not include super()
public ${desc.Name}()
{
getAttributes().setType("$desc.Name");
}
was (Author: cciatti):
because the template does not include super()
public ${desc.Name}() {
getAttributes().setType("$desc.Name");
}
> camel-salesforce - Maven plugin generated code AbstractDescribedSObjectBase can cause NPE
> -----------------------------------------------------------------------------------------
>
> Key: CAMEL-16516
> URL: https://issues.apache.org/jira/browse/CAMEL-16516
> Project: Camel
> Issue Type: Bug
> Components: camel-salesforce
> Reporter: Claus Ibsen
> Priority: Major
> Fix For: 3.10.0
>
>
> The Maven plugin for camel-salesforce component has an issue. The constructor of the generated classes extending AbstractDescribedSObjectBase has a single line
> getAttributes().setType("$desc.Name");
> The issue is that AbstractDescribedSObjectBase does not initialize attributes, so getAttributes() returns null and I am getting nullpointerexception. I manually fixed on the generated code but, it is better if it gets fixed directly in the sobject-pojo.vm file.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)