You are viewing a plain text version of this content. The canonical link for it is here.
Posted to gitbox@activemq.apache.org by GitBox <gi...@apache.org> on 2022/07/13 14:11:51 UTC
[GitHub] [activemq-artemis] clebertsuconic commented on a diff in pull request #4147: ARTEMIS-3894 - add conversion from string for list - allow core bridg…
clebertsuconic commented on code in PR #4147:
URL: https://github.com/apache/activemq-artemis/pull/4147#discussion_r920129394
##########
artemis-server/src/main/java/org/apache/activemq/artemis/core/config/impl/ConfigurationImpl.java:
##########
@@ -550,6 +550,17 @@ public <T> T convert(Class<T> type, Object value) {
}
}, TransformerConfiguration.class);
+ beanUtils.getConvertUtils().register(new Converter() {
+ @Override
+ public <T> T convert(Class<T> type, Object value) {
+ List convertedValue = new ArrayList<String>();
+ for (String entry : value.toString().split(",")) {
Review Comment:
I have been following some error prone messages, and this particular line will introduce an error prone warning.
WARNING] /Users/clebertsuconic/work/apache/activemq-artemis/artemis-commons/src/main/java/org/apache/activemq/artemis/utils/uri/URIFactory.java:[112,86] [StringSplitter] String.split(String) has surprising behavior
(see https://errorprone.info/bugpattern/StringSplitter)
Did you mean 'List<String> connectorURIS = Splitter.on(',').splitToList(split[0].substring(split[0].indexOf('(') + 1));'?
[
--
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: gitbox-unsubscribe@activemq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org