Uploaded image for project: 'Brooklyn'
  1. Brooklyn
  2. BROOKLYN-455

Web-console for inherited config uses wrong DSL evaluation context

Attach filesAttach ScreenshotAdd voteVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • None
    • None
    • None

    Description

      With 0.11.0-SNAPSHOT, I deployed the app shown below:

      services:
        - type: org.apache.brooklyn.entity.stock.BasicApplication
          brooklyn.config:
            ownConfig: parentValue
            exampleConfig: '$brooklyn:config("ownConfig")'
          brooklyn.children:
            - type: org.apache.brooklyn.entity.stock.BasicEntity
              brooklyn.config:
                ownConfig: childValue
                refExampleConfig: '$brooklyn:config("exampleConfig")'
      

      As expected, the refExampleConfig gets the "exampleConfig" value, which is a DSL evaluated in the context of the entity that declares it. It therefore has the value parentValue.

      However, the web-console's view of the child entity's config also shows the inherited config exampleConfig. It shows the value childValue, which I think is wrong -
      it has evaluated the $brooklyn:config("ownConfig") in the context of the child entity instead of the parent. As demonstrated by refExampleConfig, it would have a different value if actually used.

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            Unassigned Unassigned
            aled.sage Aled Sage

            Dates

              Created:
              Updated:

              Slack

                Issue deployment