Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-16196

(7.2.z) JBTM-3049 - Setting properties via arjPropertyManager should affect all related config bean instances

XMLWordPrintable

      Narayana configuration is performed through named configuration beans. For example the ObjectStoreEnvironmentBean has three instances for configuring different store types:

      • the action store (default)
      • the stateStore (with the name "stateStore")
      • the communicationsStore (with the name "communicationsStore")

      Each of the stores have their own getters and setters.

      We also have the arjPropertyManager API which returns the default configuration beans:

          public static CoreEnvironmentBean getCoreEnvironmentBean();
          public static CoordinatorEnvironmentBean getCoordinatorEnvironmentBean();
          public static ObjectStoreEnvironmentBean getObjectStoreEnvironmentBean();
      

      For example the getObjectStoreEnvironmentBean() call returns the config for the action store.

      Historically (ie before we moved to using configuration beans) the user could set all config properties via the single instance of arjPropertyManager. For example, if the user wanted to disable file system sync'ing for the object store he would obtain an arjuna PropertyManager with which he could set a single property called OBJECTSTORE_SYNC and the setting would be applied to all writes to the object store. However, with the new/current config mechanism he would need to call the setter on each known instance of the ObjectStoreEnvironmentBean:

      BeanPopulator.getNamedInstance(ObjectStoreEnvironmentBean.class, "communicationStore").setObjectStoreSync(false);
      BeanPopulator.getNamedInstance(ObjectStoreEnvironmentBean.class, "stateStore").setObjectStoreSync(false);
      BeanPopulator.getDefaultInstance(ObjectStoreEnvironmentBean.class).setObjectStoreSync(false);
      

      This JIRA is to return to the original behaviour where calling the setters of the beans returned from arjPropertyManager should be applied to all named instances of the returned bean.

      The semantics of calling the getters needs be discussed and defined.

              spyrkob Bartosz Spyrko-Smietanko
              spyrkob Bartosz Spyrko-Smietanko
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: