Uploaded image for project: 'Talend Component Kit'
  1. Talend Component Kit
  2. TCOMP-960

Suggestions parameters are not correctly resolved in Studio

Apply templateInsert Lucidchart DiagramXMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • 1.0.4
    • None
    • None
    • All
    • Small

      Consider following UI Option:
      @Option
      @Suggestable(value = "basedOnComplex", parameters =

      {"dataStore", "complex"}

      )
      private String basedOnComplex;

      and following Suggestions method:
      @Suggestions("basedOnComplex")
      public SuggestionValues basedOnComplex(@Option("ds") final QASuggestionsDatastore store, @Option("c") final ComplexConfig complex) {

      ActionReference contains SimplePropertyDefinition, which are sorted in alphabetic order(in case several properties are located on the same level in the tree) . Thus, in ActionProperty property "c" goes before property "ds". The order of properties in ActionReference is different than relative paths order in Suggestable.parameters().

      However, integration in Studio expects action properties in the same order as relative paths.
      This should be fixed.

      See:
      https://github.com/Talend/component-runtime-qa/blob/master/components/qa/src/main/java/org/talend/components/qa/actions/QASuggestionsDataset.java#L83-L86
      https://github.com/Talend/component-runtime-qa/blob/master/components/qa/src/main/java/org/talend/components/qa/actions/QASuggestionsService.java#L58-L59

      Workaround for component dev:
      ensure Suggestions method parameters go in alphabetic order.

            Unassigned Unassigned
            igonchar Ivan Gonchar
            Ivan Gonchar
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: