You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by ro...@apache.org on 2018/04/30 07:24:52 UTC

[cloudstack] branch master updated: CLOUDSTACK-10360: Change the method name. (#2598)

This is an automated email from the ASF dual-hosted git repository.

rohit pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/cloudstack.git


The following commit(s) were added to refs/heads/master by this push:
     new 93509a4  CLOUDSTACK-10360: Change the method name. (#2598)
93509a4 is described below

commit 93509a431cde8452037e79f7b85584a2a3c025df
Author: Kui LIU <br...@gmail.com>
AuthorDate: Mon Apr 30 09:24:47 2018 +0200

    CLOUDSTACK-10360: Change the method name. (#2598)
    
    The method is named as "scoped" that seems to whether the variable config is scoped in _scopedStorages or not. Actually, the method tries to find a storage of which scope equals to the scope of config. So that, the method name "findStorage" should be more clear than "scoped".
---
 .../src/main/java/org/apache/cloudstack/framework/config/ConfigKey.java | 2 +-
 .../org/apache/cloudstack/framework/config/impl/ConfigDepotImpl.java    | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/framework/config/src/main/java/org/apache/cloudstack/framework/config/ConfigKey.java b/framework/config/src/main/java/org/apache/cloudstack/framework/config/ConfigKey.java
index 1734b98..2ace24d 100644
--- a/framework/config/src/main/java/org/apache/cloudstack/framework/config/ConfigKey.java
+++ b/framework/config/src/main/java/org/apache/cloudstack/framework/config/ConfigKey.java
@@ -152,7 +152,7 @@ public class ConfigKey<T> {
             return value();
         }
 
-        String value = s_depot != null ? s_depot.scoped(this).getConfigValue(id, this) : null;
+        String value = s_depot != null ? s_depot.findScopedConfigStorage(this).getConfigValue(id, this) : null;
         if (value == null) {
             return value();
         } else {
diff --git a/framework/config/src/main/java/org/apache/cloudstack/framework/config/impl/ConfigDepotImpl.java b/framework/config/src/main/java/org/apache/cloudstack/framework/config/impl/ConfigDepotImpl.java
index 6a85b90..bb49ce1 100644
--- a/framework/config/src/main/java/org/apache/cloudstack/framework/config/impl/ConfigDepotImpl.java
+++ b/framework/config/src/main/java/org/apache/cloudstack/framework/config/impl/ConfigDepotImpl.java
@@ -166,7 +166,7 @@ public class ConfigDepotImpl implements ConfigDepot, ConfigDepotAdmin {
         return _configDao;
     }
 
-    public ScopedConfigStorage scoped(ConfigKey<?> config) {
+    public ScopedConfigStorage findScopedConfigStorage(ConfigKey<?> config) {
         for (ScopedConfigStorage storage : _scopedStorages) {
             if (storage.getScope() == config.scope()) {
                 return storage;

-- 
To stop receiving notification emails like this one, please contact
rohit@apache.org.