Github user neykov commented on a diff in the pull request:

    https://github.com/apache/brooklyn-server/pull/358#discussion_r81121259
  
    --- Diff: 
api/src/main/java/org/apache/brooklyn/api/catalog/CatalogConfig.java ---
    @@ -34,5 +34,7 @@
          * a higher value appears higher in the list. the default is 1.
          * (negative values may be used to indicate advanced config which 
might not be shown unless requested.) */ 
         double priority() default 1;
    -    
    +
    +     /** a pinned configuration means that it should be displayed, 
regardless of its priority */
    +    boolean pinned() default false;
    --- End diff --
    
    The `@CatalogConfig` annotation is set on items that we want visible in the 
catalog. To prevent an item from being seen by default one can set a negative 
priority above. This allows for having an order of the keys and at the same 
time declares whether they should be visible or not. Could keep the existing 
behaviour and not expose `pinned` here (derive it instead from priority). But 
having `pinned` might be more user friendly so I'm fine keeping it as is.
    
    Can you update the javadoc above - doesn't make sense to support negative 
priorities any more. They make documenting and understanding the behaviour more 
difficult when paired with `pinned`. Let's keep the behaviour for backwards 
compatibility, but not advertise it.



---
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 infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to