dominikriemer commented on issue #1688: URL: https://github.com/apache/streampipes/issues/1688#issuecomment-1697979951
Hi @muyangye and thanks for the PR! Here are some answers to your questions: * Instead of Labels.from, you can use `Labels.withId` by providing an ID only. By doing so, you can provide a `strings.en` file in the resources folder where you can provide titles and descriptions for every ID that you refer to. The advantage is that this approach allows us to add more translations in the future, once a multi-language StreamPipes version is available. There are many examples in the `streampipes-extensions` folder, e.g., `streampipes-processors-filters-jvm` that might help to see how IDs can be provided. * I think conventional rounding is ok, or we could think of an advanced version where the user could provide the number of digits to round to. * The icon can also be placed in the resources folder similar to the `strings.en` file. In addition, a markdown file with a documentation of these elements can be placed here. I hope the examples in the extensions folder are helpful (the `appId` of the pipeline element must match the folder name in the resources folder. * The reason why we use a prefix here is that a pipeline element can have more than one input stream, where both streams provide fields with the same name. To uniquely identify a field, we use the selector. Since there is only one output stream, this is not needed when adding a new field to the event. You could also use the `updateFieldBySelector` method to update the field, and I think there is also a method like `getFieldNameOut` which should return the field name without selector. Hope this helps! Please feel free to ask in case I did not properly answer your questions. Thanks again for your contribution! -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@streampipes.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org