[jira] [Commented] (DIRKRB-511) Load configuration content when adding the resource
[ https://issues.apache.org/jira/browse/DIRKRB-511?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15071373#comment-15071373 ] Jiajia Li commented on DIRKRB-511: -- V2 looks great to me, I will commit it, thanks Yan's work and Kai's review. > Load configuration content when adding the resource > --- > > Key: DIRKRB-511 > URL: https://issues.apache.org/jira/browse/DIRKRB-511 > Project: Directory Kerberos > Issue Type: Improvement >Affects Versions: 1.0.0-RC2 >Reporter: YanYan >Assignee: YanYan > Attachments: DIRKRB-511-v1.patch, DIRKRB-511-v2.patch > > > Currently when loading Config resources, we only load in the resource name, > and actually load in the content at the time we first launch a query, etc, > getDefaultRealm(). > In order to reduce errors when loading contents and discover errors as soon > as possible, we will load the resource name and contents in one step. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (DIRKRB-511) Load configuration content when adding the resource
[ https://issues.apache.org/jira/browse/DIRKRB-511?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15071376#comment-15071376 ] YanYan commented on DIRKRB-511: --- Thanks Jiajia's commitment, and thanks Kai's reivew - it helped improve a lot! > Load configuration content when adding the resource > --- > > Key: DIRKRB-511 > URL: https://issues.apache.org/jira/browse/DIRKRB-511 > Project: Directory Kerberos > Issue Type: Improvement >Affects Versions: 1.0.0-RC2 >Reporter: YanYan >Assignee: YanYan > Attachments: DIRKRB-511-v1.patch, DIRKRB-511-v2.patch > > > Currently when loading Config resources, we only load in the resource name, > and actually load in the content at the time we first launch a query, etc, > getDefaultRealm(). > In order to reduce errors when loading contents and discover errors as soon > as possible, we will load the resource name and contents in one step. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (DIRKRB-511) Load configuration content when adding the resource
[ https://issues.apache.org/jira/browse/DIRKRB-511?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15070766#comment-15070766 ] Kai Zheng commented on DIRKRB-511: -- Never mind, but I guess you can edit the comment if you'd like to. > Load configuration content when adding the resource > --- > > Key: DIRKRB-511 > URL: https://issues.apache.org/jira/browse/DIRKRB-511 > Project: Directory Kerberos > Issue Type: Improvement >Affects Versions: 1.0.0-RC2 >Reporter: YanYan >Assignee: YanYan > Attachments: DIRKRB-511-v1.patch, DIRKRB-511-v2.patch > > > Currently when loading Config resources, we only load in the resource name, > and actually load in the content at the time we first launch a query, etc, > getDefaultRealm(). > In order to reduce errors when loading contents and discover errors as soon > as possible, we will load the resource name and contents in one step. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (DIRKRB-511) Load configuration content when adding the resource
[ https://issues.apache.org/jira/browse/DIRKRB-511?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15070764#comment-15070764 ] YanYan commented on DIRKRB-511: --- Sorry for the format;) It is my first attempt to use advanced formatting. > Load configuration content when adding the resource > --- > > Key: DIRKRB-511 > URL: https://issues.apache.org/jira/browse/DIRKRB-511 > Project: Directory Kerberos > Issue Type: Improvement >Affects Versions: 1.0.0-RC2 >Reporter: YanYan >Assignee: YanYan > Attachments: DIRKRB-511-v1.patch, DIRKRB-511-v2.patch > > > Currently when loading Config resources, we only load in the resource name, > and actually load in the content at the time we first launch a query, etc, > getDefaultRealm(). > In order to reduce errors when loading contents and discover errors as soon > as possible, we will load the resource name and contents in one step. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (DIRKRB-511) Load configuration content when adding the resource
[ https://issues.apache.org/jira/browse/DIRKRB-511?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15070710#comment-15070710 ] Kai Zheng commented on DIRKRB-511: -- With this change there would be no good place to call the following. I guess we would not need {{propNames}} now in {{ConfigImpl}} since configuration items are loaded immediately once the resource is added. {code} private void reloadNames() { if (propNames != null) { propNames.clear(); } propNames = new HashSet(properties.keySet()); for (Config config : configs) { propNames.addAll(config.getNames()); } } {code} > Load configuration content when adding the resource > --- > > Key: DIRKRB-511 > URL: https://issues.apache.org/jira/browse/DIRKRB-511 > Project: Directory Kerberos > Issue Type: Improvement >Affects Versions: 1.0.0-RC2 >Reporter: YanYan >Assignee: YanYan > Attachments: DIRKRB-511-v1.patch > > > Currently when loading Config resources, we only load in the resource name, > and actually load in the content at the time we first launch a query, etc, > getDefaultRealm(). > In order to reduce errors when loading contents and discover errors as soon > as possible, we will load the resource name and contents in one step. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (DIRKRB-511) Load configuration content when adding the resource
[ https://issues.apache.org/jira/browse/DIRKRB-511?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15070699#comment-15070699 ] Kai Zheng commented on DIRKRB-511: -- Thanks [~Alice Yan] for this! This would make the {{Conf}} look much clean and less error-prone now. The patch looks good. I guess you accidentally deleted the method {{reload()}}? I thought it's still needed. By the way, would you add {{synchronized}} for each mutate like method so it can be thread safe? Thus it can be used more robustly even when we won't update a {{Conf}} in concurrent context. By the way, did it build successfully without skipping tests and style checks? I don't check the patch yet so please ignore this if you did :). Thanks. > Load configuration content when adding the resource > --- > > Key: DIRKRB-511 > URL: https://issues.apache.org/jira/browse/DIRKRB-511 > Project: Directory Kerberos > Issue Type: Improvement >Affects Versions: 1.0.0-RC2 >Reporter: YanYan >Assignee: YanYan > Attachments: DIRKRB-511-v1.patch > > > Currently when loading Config resources, we only load in the resource name, > and actually load in the content at the time we first launch a query, etc, > getDefaultRealm(). > In order to reduce errors when loading contents and discover errors as soon > as possible, we will load the resource name and contents in one step. -- This message was sent by Atlassian JIRA (v6.3.4#6332)