Hi, I'm trying to add a custom data type to my smart service. Wit

Hi,

I'm trying to add a custom data type to my smart service. Without CDT declaration, I can install the smart service but if I add it, I get this message in the application-server.log :

com.atlassian.plugin.PluginException: com.appiancorp.type.config.pojo.PojoTypeImportException: Could not generate XSDs for the classes [class com.solypse.etde.etde_import]. Cause: com.sun.xml.bind.v2.runtime.IllegalAnnotationsException: 1 counts of IllegalAnnotationExceptions (APNX-1-4166-001)

I just added the "netbean" cdt example, it's my first test and I'm not so good with Java so excuse me if the answer is obvious.

I'm using Appian 7 and jre 1.6

Thanks,

Olivier

appian-plugin.xml :
---------------------------------
...
          <datatype key="et_importDTin" name="Et Import Data Type">
<class>com.solse.et.et_import</class>
</datatype>

<smart-service name="et_import" key="et_import"
class="com.solse.et.et_import" />
</appian-plugin>
---------------------...

OriginalPostID-57953

OriginalPostID-57953

  Discussion posts and replies are publicly visible

Parents
  • The way that I typically create CDTs as java objects are as their own java file outside of my plugin. To do so take the following steps:

    1. Create another java file called SampleBean.java with the correct package name and package imports which for you would be the JAXB Annotation example from this page: forum.appian.com/.../Defining_a_Custom_Data_Type

    with this at the top:

    package com.solse.et;

    import javax.xml.bind.annotation.XmlElement;
    import javax.xml.bind.annotation.XmlRootElement;
    import javax.xml.bind.annotation.XmlType;

    2. Change the private static class SampleBean to public class SampleBean

    3. Change your datatype in your plugin to be:

    <datatype key="et_importDTin" name="Et Import Data Type">
    <class>com.solse.et.SampleBean</class>
    </datatype>

    Let me know if that works for you.
Reply
  • The way that I typically create CDTs as java objects are as their own java file outside of my plugin. To do so take the following steps:

    1. Create another java file called SampleBean.java with the correct package name and package imports which for you would be the JAXB Annotation example from this page: forum.appian.com/.../Defining_a_Custom_Data_Type

    with this at the top:

    package com.solse.et;

    import javax.xml.bind.annotation.XmlElement;
    import javax.xml.bind.annotation.XmlRootElement;
    import javax.xml.bind.annotation.XmlType;

    2. Change the private static class SampleBean to public class SampleBean

    3. Change your datatype in your plugin to be:

    <datatype key="et_importDTin" name="Et Import Data Type">
    <class>com.solse.et.SampleBean</class>
    </datatype>

    Let me know if that works for you.
Children
No Data