Github user kiuby88 commented on a diff in the pull request:
https://github.com/apache/brooklyn-server/pull/136#discussion_r65145653
--- Diff:
software/base/src/main/java/org/apache/brooklyn/entity/software/base/InboundPortsUtils.java
---
@@ -77,12 +82,17 @@
Set<ConfigKey<?>> configKeys =
Sets.newHashSet(extraConfigKeys);
configKeys.addAll(entity.getEntityType().getConfigKeys());
// Also add dynamically added config keys
-
configKeys.addAll(((EntityInternal)entity).config().getBag().getAllConfigAsConfigKeyMap().keySet());
+ Map<ConfigKey<?>, ?> configuredConfigKeys =
ImmutableMap.copyOf(((EntityInternal)
entity).config().getBag().getAllConfigAsConfigKeyMap());
+ configKeys.addAll(configuredConfigKeys.keySet());
--- End diff --
@aledsage, thanks a lot for your explanation.
I see the problem about `ImmutableMap` now and I understand the difference
between both of them, so I will use `MutableMap`.
About the exception, the method terminated propagating a
`NullPointerException` and I saw a `NullPointerException` in the console, but I
did not understand why a `NullPointerException` was thrown. Then, I found an
`InterruptedException` in the stack. I do not know if it makes sense for you,
but this `InterruptedException` helped me to understand the problem and then I
decided to save a copy of the information that was being accessed.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---