tamaya-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From anat...@apache.org
Subject [1/3] incubator-tamaya git commit: TAMAYA-26: replaced creation methods with of(XXX) in PropertySourceBuilder. TAMAYA-3: Updated documentation. TAMAYA-25: Adapted component loading.
Date Sun, 14 Dec 2014 23:50:56 GMT
Repository: incubator-tamaya
Updated Branches:
  refs/heads/master 9ac2684f8 -> c6fa7c677


http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/main/java/org/apache/tamaya/core/internal/env/SystemClassLoaderEnvironmentProvider.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/tamaya/core/internal/env/SystemClassLoaderEnvironmentProvider.java b/core/src/main/java/org/apache/tamaya/core/internal/env/SystemClassLoaderEnvironmentProvider.java
index 2f941a4..d455bce 100644
--- a/core/src/main/java/org/apache/tamaya/core/internal/env/SystemClassLoaderEnvironmentProvider.java
+++ b/core/src/main/java/org/apache/tamaya/core/internal/env/SystemClassLoaderEnvironmentProvider.java
@@ -23,7 +23,7 @@ import org.apache.tamaya.Stage;
 import org.apache.tamaya.core.config.ConfigurationFormats;
 import org.apache.tamaya.core.env.EnvironmentBuilder;
 import org.apache.tamaya.core.resource.Resource;
-import org.apache.tamaya.spi.Bootstrap;
+import org.apache.tamaya.spi.ServiceContext;
 import org.apache.tamaya.core.spi.ConfigurationFormat;
 import org.apache.tamaya.core.spi.EnvironmentProvider;
 import org.apache.tamaya.core.resource.ResourceLoader;
@@ -59,7 +59,7 @@ public class SystemClassLoaderEnvironmentProvider implements EnvironmentProvider
         if(env!=null){
             return env;
         }
-        List<Resource> propertyResources = Bootstrap.getService(ResourceLoader.class).getResources(ClassLoader.getSystemClassLoader(),
+        List<Resource> propertyResources = ServiceContext.getInstance().getSingleton(ResourceLoader.class).getResources(ClassLoader.getSystemClassLoader(),
                 "classpath:META-INF/env/system.properties", "classpath:META-INF/env/system.xml", "classpath:META-INF/env/system.ini");
         EnvironmentBuilder builder = EnvironmentBuilder.of("system", getEnvironmentType());
         for(Resource resource:propertyResources){

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/main/java/org/apache/tamaya/core/internal/format/DefaultConfigFormatsSingletonSpi.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/tamaya/core/internal/format/DefaultConfigFormatsSingletonSpi.java b/core/src/main/java/org/apache/tamaya/core/internal/format/DefaultConfigFormatsSingletonSpi.java
index 31d226a..0bf5728 100644
--- a/core/src/main/java/org/apache/tamaya/core/internal/format/DefaultConfigFormatsSingletonSpi.java
+++ b/core/src/main/java/org/apache/tamaya/core/internal/format/DefaultConfigFormatsSingletonSpi.java
@@ -25,7 +25,7 @@ import org.apache.tamaya.core.spi.ConfigurationFormatsSingletonSpi;
 import java.util.*;
 import java.util.stream.Collectors;
 
-import org.apache.tamaya.spi.Bootstrap;
+import org.apache.tamaya.spi.ServiceContext;
 
 /**
  * Singleton accessor to access registered reader mechanism.
@@ -35,7 +35,7 @@ public final class DefaultConfigFormatsSingletonSpi implements ConfigurationForm
     public ConfigurationFormat getFormat(String formatName){
         Objects.requireNonNull(formatName);
         try {
-            for (ConfigurationFormat configFormat : Bootstrap.getServices(ConfigurationFormat.class)) {
+            for (ConfigurationFormat configFormat : ServiceContext.getInstance().getServices(ConfigurationFormat.class)) {
                 if(formatName.equals(configFormat.getFormatName())){
                     return configFormat;
                 }
@@ -50,7 +50,7 @@ public final class DefaultConfigFormatsSingletonSpi implements ConfigurationForm
     public Collection<String> getFormatNames(){
         Set<String> result = new HashSet<>();
         try {
-            result.addAll(Bootstrap.getServices(ConfigurationFormat.class).stream().map(ConfigurationFormat::getFormatName)
+            result.addAll(ServiceContext.getInstance().getServices(ConfigurationFormat.class).stream().map(ConfigurationFormat::getFormatName)
                     .collect(Collectors.toList()));
         } catch (Exception e) {
             // TODO: handle exception
@@ -62,7 +62,7 @@ public final class DefaultConfigFormatsSingletonSpi implements ConfigurationForm
 	public ConfigurationFormat getFormat(Resource resource) {
         Objects.requireNonNull(resource);
         try {
-            for (ConfigurationFormat configFormat : Bootstrap.getServices(ConfigurationFormat.class)) {
+            for (ConfigurationFormat configFormat : ServiceContext.getInstance().getServices(ConfigurationFormat.class)) {
                 if(configFormat.isAccepted(resource)){
                     return configFormat;
                 }

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/main/java/org/apache/tamaya/core/internal/resources/DefaultPathResourceLoader.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/tamaya/core/internal/resources/DefaultPathResourceLoader.java b/core/src/main/java/org/apache/tamaya/core/internal/resources/DefaultPathResourceLoader.java
index 15050f5..50c0402 100644
--- a/core/src/main/java/org/apache/tamaya/core/internal/resources/DefaultPathResourceLoader.java
+++ b/core/src/main/java/org/apache/tamaya/core/internal/resources/DefaultPathResourceLoader.java
@@ -22,7 +22,7 @@ import org.apache.tamaya.core.spi.PathResolver;
 import org.apache.tamaya.core.resource.Resource;
 import org.apache.tamaya.core.resource.ResourceLoader;
 
-import org.apache.tamaya.spi.Bootstrap;
+import org.apache.tamaya.spi.ServiceContext;
 
 import java.util.*;
 import java.util.logging.Level;
@@ -38,7 +38,7 @@ public class DefaultPathResourceLoader implements ResourceLoader{
 
     @Override
     public Collection<String> getResolverIds(){
-        return Bootstrap.getServices(PathResolver.class).stream().map(PathResolver::getResolverId)
+        return ServiceContext.getInstance().getServices(PathResolver.class).stream().map(PathResolver::getResolverId)
                 .collect(Collectors.toSet());
     }
 
@@ -68,7 +68,7 @@ public class DefaultPathResourceLoader implements ResourceLoader{
     @Override
     public List<Resource> getResources(ClassLoader classLoader, Collection<String> expressions){
         List<Resource> resources = new ArrayList<>();
-        for(PathResolver resolver : Bootstrap.getServices(PathResolver.class)){
+        for(PathResolver resolver : ServiceContext.getInstance().getServices(PathResolver.class)){
             try{
                 resources.addAll(resolver.resolve(classLoader, expressions));
             }

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/main/java/org/apache/tamaya/core/internal/resources/io/AbstractResource.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/tamaya/core/internal/resources/io/AbstractResource.java b/core/src/main/java/org/apache/tamaya/core/internal/resources/io/AbstractResource.java
index a8a3ba3..a1c91a5 100644
--- a/core/src/main/java/org/apache/tamaya/core/internal/resources/io/AbstractResource.java
+++ b/core/src/main/java/org/apache/tamaya/core/internal/resources/io/AbstractResource.java
@@ -173,7 +173,7 @@ public abstract class AbstractResource implements Resource {
 	 */
 	@Override
 	public Resource createRelative(String relativePath) throws IOException {
-		throw new FileNotFoundException("Cannot create a relative resource for " + getDescription());
+		throw new FileNotFoundException("Cannot of a relative resource for " + getDescription());
 	}
 
 	/**

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/main/java/org/apache/tamaya/core/internal/resources/io/ClassUtils.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/tamaya/core/internal/resources/io/ClassUtils.java b/core/src/main/java/org/apache/tamaya/core/internal/resources/io/ClassUtils.java
index d83e6d0..82b9d6e 100644
--- a/core/src/main/java/org/apache/tamaya/core/internal/resources/io/ClassUtils.java
+++ b/core/src/main/java/org/apache/tamaya/core/internal/resources/io/ClassUtils.java
@@ -1141,7 +1141,7 @@ public class ClassUtils {
 //	 * implementing the given interfaces in one single Class.
 //	 * <p>This implementation builds a JDK proxy class for the given interfaces.
 //	 * @param interfaces the interfaces to merge
-//	 * @param classLoader the ClassLoader to create the composite Class in
+//	 * @param classLoader the ClassLoader to of the composite Class in
 //	 * @return the merged interface as Class
 //	 * @see java.lang.reflect.Proxy#getProxyClass
 //	 */

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/main/java/org/apache/tamaya/core/properties/AbstractClasspathAwarePropertySource.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/tamaya/core/properties/AbstractClasspathAwarePropertySource.java b/core/src/main/java/org/apache/tamaya/core/properties/AbstractClasspathAwarePropertySource.java
index e35dfd4..ab8c2ab 100644
--- a/core/src/main/java/org/apache/tamaya/core/properties/AbstractClasspathAwarePropertySource.java
+++ b/core/src/main/java/org/apache/tamaya/core/properties/AbstractClasspathAwarePropertySource.java
@@ -19,7 +19,7 @@
 package org.apache.tamaya.core.properties;
 
 import org.apache.tamaya.core.resource.Resource;
-import org.apache.tamaya.spi.Bootstrap;
+import org.apache.tamaya.spi.ServiceContext;
 import org.apache.tamaya.core.resource.ResourceLoader;
 
 import org.apache.tamaya.MetaInfo;
@@ -52,7 +52,7 @@ public abstract class AbstractClasspathAwarePropertySource extends AbstractPrope
                       .build());
         Objects.requireNonNull(sources, "sources required.");
         Objects.requireNonNull(sourceExpression, "sourceExpression required.");
-        List<Resource> resources = Bootstrap.getService(ResourceLoader.class).getResources(classLoader, sourceExpression);
+        List<Resource> resources = ServiceContext.getInstance().getSingleton(ResourceLoader.class).getResources(classLoader, sourceExpression);
         for(Resource res : resources){
             addSource(res.toString());
         }

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/main/java/org/apache/tamaya/core/properties/IntersectingPropertySource.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/tamaya/core/properties/IntersectingPropertySource.java b/core/src/main/java/org/apache/tamaya/core/properties/IntersectingPropertySource.java
index 39daabf..b0fb90c 100644
--- a/core/src/main/java/org/apache/tamaya/core/properties/IntersectingPropertySource.java
+++ b/core/src/main/java/org/apache/tamaya/core/properties/IntersectingPropertySource.java
@@ -19,7 +19,6 @@
 package org.apache.tamaya.core.properties;
 
 import org.apache.tamaya.*;
-import org.apache.tamaya.core.properties.AbstractPropertySource;
 
 import java.util.*;
 import java.util.stream.Collectors;
@@ -37,7 +36,7 @@ class IntersectingPropertySource extends AbstractPropertySource {
     public IntersectingPropertySource(MetaInfo metaInfo, AggregationPolicy policy, List<PropertySource> providers) {
         super(MetaInfoBuilder.of(metaInfo).setType("intersection").build());
         this.providers = new ArrayList<>(providers);
-        aggregatedDelegate = PropertySourceBuilder.create(getMetaInfo()).withAggregationPolicy(policy)
+        aggregatedDelegate = PropertySourceBuilder.of(getMetaInfo()).withAggregationPolicy(policy)
                 .addProviders(this.providers).build();
     }
 

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/main/java/org/apache/tamaya/core/properties/PathBasedPropertySource.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/tamaya/core/properties/PathBasedPropertySource.java b/core/src/main/java/org/apache/tamaya/core/properties/PathBasedPropertySource.java
index e6ea041..0c23394 100644
--- a/core/src/main/java/org/apache/tamaya/core/properties/PathBasedPropertySource.java
+++ b/core/src/main/java/org/apache/tamaya/core/properties/PathBasedPropertySource.java
@@ -20,16 +20,15 @@ package org.apache.tamaya.core.properties;
 
 import org.apache.tamaya.*;
 import org.apache.tamaya.core.config.ConfigurationFormats;
-import org.apache.tamaya.core.properties.AbstractPropertySource;
 import org.apache.tamaya.core.resource.Resource;
-import org.apache.tamaya.spi.Bootstrap;
+import org.apache.tamaya.spi.ServiceContext;
 import org.apache.tamaya.core.spi.ConfigurationFormat;
 import org.apache.tamaya.core.resource.ResourceLoader;
 
 import java.util.*;
 
 /**
- * Created by Anatole on 16.10.2014.
+ * Implementation of a PropertySource that reads configuration from some given resource paths.
  */
 final class PathBasedPropertySource extends AbstractPropertySource {
 
@@ -54,7 +53,7 @@ final class PathBasedPropertySource extends AbstractPropertySource {
         List<String> effectivePaths = new ArrayList<>();
         paths.forEach((path) -> {
             effectivePaths.add(path);
-            for (Resource res : Bootstrap.getService(ResourceLoader.class).getResources(path)) {
+            for (Resource res : ServiceContext.getInstance().getSingleton(ResourceLoader.class).getResources(path)) {
                 ConfigurationFormat format = ConfigurationFormats.getFormat(res);
                 if (format != null) {
                     try {

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/main/java/org/apache/tamaya/core/properties/PropertySourceBuilder.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/tamaya/core/properties/PropertySourceBuilder.java b/core/src/main/java/org/apache/tamaya/core/properties/PropertySourceBuilder.java
index 2347712..3c96e84 100644
--- a/core/src/main/java/org/apache/tamaya/core/properties/PropertySourceBuilder.java
+++ b/core/src/main/java/org/apache/tamaya/core/properties/PropertySourceBuilder.java
@@ -86,7 +86,7 @@ public final class PropertySourceBuilder {
      * @param provider the base provider to be used, not null.
      * @return a new builder instance, never null.
      */
-    public static PropertySourceBuilder create(PropertySource provider) {
+    public static PropertySourceBuilder of(PropertySource provider) {
         return new PropertySourceBuilder(provider);
     }
 
@@ -96,7 +96,7 @@ public final class PropertySourceBuilder {
      * @param metaInfo the meta information, not null.
      * @return a new builder instance, never null.
      */
-    public static PropertySourceBuilder create(MetaInfo metaInfo) {
+    public static PropertySourceBuilder of(MetaInfo metaInfo) {
         return new PropertySourceBuilder(metaInfo);
     }
 
@@ -106,7 +106,7 @@ public final class PropertySourceBuilder {
      * @param name the provider name, not null.
      * @return a new builder instance, never null.
      */
-    public static PropertySourceBuilder create(String name) {
+    public static PropertySourceBuilder of(String name) {
         return new PropertySourceBuilder(Objects.requireNonNull(name));
     }
 
@@ -115,7 +115,7 @@ public final class PropertySourceBuilder {
      *
      * @return a new builder instance, never null.
      */
-    public static PropertySourceBuilder create() {
+    public static PropertySourceBuilder of() {
         return new PropertySourceBuilder("<noname>");
     }
 

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/main/java/org/apache/tamaya/core/spi/ConfigurationProviderSpi.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/tamaya/core/spi/ConfigurationProviderSpi.java b/core/src/main/java/org/apache/tamaya/core/spi/ConfigurationProviderSpi.java
index 09eb8f9..e60a53d 100644
--- a/core/src/main/java/org/apache/tamaya/core/spi/ConfigurationProviderSpi.java
+++ b/core/src/main/java/org/apache/tamaya/core/spi/ConfigurationProviderSpi.java
@@ -21,7 +21,7 @@ package org.apache.tamaya.core.spi;
 import org.apache.tamaya.Configuration;
 
 /**
-* This configuration provider SPI allows to register the effective factory logic to create and manage a configuration
+* This configuration provider SPI allows to register the effective factory logic to of and manage a configuration
 * instance. Hereby the qualifiers determine the type current configuration. By default
 */
 public interface ConfigurationProviderSpi{

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/main/java/org/apache/tamaya/core/spi/EnvironmentProvider.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/tamaya/core/spi/EnvironmentProvider.java b/core/src/main/java/org/apache/tamaya/core/spi/EnvironmentProvider.java
index b40cbb6..0d42b8b 100644
--- a/core/src/main/java/org/apache/tamaya/core/spi/EnvironmentProvider.java
+++ b/core/src/main/java/org/apache/tamaya/core/spi/EnvironmentProvider.java
@@ -43,7 +43,7 @@ public interface EnvironmentProvider {
     boolean isEnvironmentActive();
 
     /**
-     * Access (or create) a new environment for the given context.
+     * Access (or of) a new environment for the given context.
      * @param parentEnvironment the parent environment to b e set
      * @return the environment, or null.
      */

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/test/java/org/apache/tamaya/JavaOneDemo.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/tamaya/JavaOneDemo.java b/core/src/test/java/org/apache/tamaya/JavaOneDemo.java
index 9182c57..fb66970 100644
--- a/core/src/test/java/org/apache/tamaya/JavaOneDemo.java
+++ b/core/src/test/java/org/apache/tamaya/JavaOneDemo.java
@@ -36,7 +36,7 @@ public class JavaOneDemo {
 
     @Test
     public void testFromSystemProperties() {
-        PropertySource prov = PropertySourceBuilder.create("Sys-conf").addSystemProperties().build();
+        PropertySource prov = PropertySourceBuilder.of("Sys-conf").addSystemProperties().build();
         assertNotNull(prov);
         for (Map.Entry<Object, Object> en : System.getProperties().entrySet()) {
             assertEquals(en.getValue(), prov.get(en.getKey().toString()).get());
@@ -45,7 +45,7 @@ public class JavaOneDemo {
 
     @Test
     public void testProgrammatixPropertySet() {
-        System.out.println(PropertySourceBuilder.create("test").addPaths("test", "classpath:test.properties"));
+        System.out.println(PropertySourceBuilder.of("test").addPaths("test", "classpath:test.properties"));
     }
 
     @Test
@@ -54,7 +54,7 @@ public class JavaOneDemo {
         Map<String, String> cfgMap = new HashMap<>();
         cfgMap.put("param1", "value1");
         cfgMap.put("a", "Adrian"); // overrides Anatole
-        Configuration config = PropertySourceBuilder.create("myTestConfig").addPaths(
+        Configuration config = PropertySourceBuilder.of("myTestConfig").addPaths(
                 "classpath:test.properties").addPaths("classpath:cfg/test.xml")
                 .addArgs(new String[]{"-arg1", "--fullarg", "fullValue", "-myflag"})
                 .addMap(cfgMap).build().toConfiguration();
@@ -70,6 +70,6 @@ public class JavaOneDemo {
         System.out.print("--- b=");
         System.out.println(config.get("b"));
         System.out.println("--- only a,b,c)");
-        System.out.println(PropertySourceBuilder.create(config).filter((f) -> f.equals("a") || f.equals("b") || f.equals("c")).build());
+        System.out.println(PropertySourceBuilder.of(config).filter((f) -> f.equals("a") || f.equals("b") || f.equals("c")).build());
     }
 }

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/test/java/org/apache/tamaya/core/properties/PropertySourceBuilderTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/tamaya/core/properties/PropertySourceBuilderTest.java b/core/src/test/java/org/apache/tamaya/core/properties/PropertySourceBuilderTest.java
index d6a4a4b..4a846f9 100644
--- a/core/src/test/java/org/apache/tamaya/core/properties/PropertySourceBuilderTest.java
+++ b/core/src/test/java/org/apache/tamaya/core/properties/PropertySourceBuilderTest.java
@@ -33,7 +33,7 @@ public class PropertySourceBuilderTest {
 
     @Test
     public void testFromEnvironmentProperties(){
-        PropertySource prov = PropertySourceBuilder.create("test").addEnvironmentProperties().build();
+        PropertySource prov = PropertySourceBuilder.of("test").addEnvironmentProperties().build();
         assertNotNull(prov);
         for(Map.Entry<String,String> en:System.getenv().entrySet()){
             assertEquals(en.getValue(), prov.get(en.getKey()).get());
@@ -42,7 +42,7 @@ public class PropertySourceBuilderTest {
 
     @Test
     public void testFromSystemProperties(){
-        PropertySource prov = PropertySourceBuilder.create("test").addSystemProperties().build();
+        PropertySource prov = PropertySourceBuilder.of("test").addSystemProperties().build();
         assertNotNull(prov);
         for(Map.Entry<Object,Object> en:System.getProperties().entrySet()){
             assertEquals(en.getValue(), prov.get(en.getKey().toString()).get());

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/test/java/org/apache/tamaya/internal/MutableTestConfigProvider.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/tamaya/internal/MutableTestConfigProvider.java b/core/src/test/java/org/apache/tamaya/internal/MutableTestConfigProvider.java
index 8c8f0c0..226faf9 100644
--- a/core/src/test/java/org/apache/tamaya/internal/MutableTestConfigProvider.java
+++ b/core/src/test/java/org/apache/tamaya/internal/MutableTestConfigProvider.java
@@ -48,7 +48,7 @@ public class MutableTestConfigProvider implements ConfigurationProviderSpi{
         dataMap.put("sons.1", "Robin");
         dataMap.put("sons.2", "Luke");
         dataMap.put("sons.3", "Benjamin");
-        PropertySource provider = PropertySourceBuilder.create(CONFIG_NAME).addMap(dataMap).build();
+        PropertySource provider = PropertySourceBuilder.of(CONFIG_NAME).addMap(dataMap).build();
         testConfig = new MutableConfiguration(dataMap, MetaInfo.of(CONFIG_NAME));
     }
 

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/test/java/org/apache/tamaya/internal/TestConfigProvider.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/tamaya/internal/TestConfigProvider.java b/core/src/test/java/org/apache/tamaya/internal/TestConfigProvider.java
index 768ac9d..60e6cb8 100644
--- a/core/src/test/java/org/apache/tamaya/internal/TestConfigProvider.java
+++ b/core/src/test/java/org/apache/tamaya/internal/TestConfigProvider.java
@@ -22,7 +22,7 @@ import org.apache.tamaya.core.properties.PropertySourceBuilder;
 import org.apache.tamaya.core.spi.ConfigurationProviderSpi;
 
 import org.apache.tamaya.Configuration;
-import org.apache.tamaya.MetaInfoBuilder;
+
 import java.util.*;
 
 /**
@@ -47,7 +47,7 @@ public class TestConfigProvider implements ConfigurationProviderSpi{
         config.put("BD", "123456789123456789123456789123456789.123456789123456789123456789123456789");
         config.put("testProperty", "value current testProperty");
         config.put("runtimeVersion", "${java.version}");
-        testConfig = PropertySourceBuilder.create("test").addMap(
+        testConfig = PropertySourceBuilder.of("test").addMap(
                 config).build().toConfiguration();
     }
 

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/test/java/org/apache/tamaya/simple/SimplePropertiesAndCLISample.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/tamaya/simple/SimplePropertiesAndCLISample.java b/core/src/test/java/org/apache/tamaya/simple/SimplePropertiesAndCLISample.java
index d6cd23a..80a6fb1 100644
--- a/core/src/test/java/org/apache/tamaya/simple/SimplePropertiesAndCLISample.java
+++ b/core/src/test/java/org/apache/tamaya/simple/SimplePropertiesAndCLISample.java
@@ -19,7 +19,6 @@
 package org.apache.tamaya.simple;
 
 import org.apache.tamaya.core.config.ConfigurationFormats;
-import org.apache.tamaya.AggregationPolicy;
 import org.apache.tamaya.core.properties.PropertySourceBuilder;
 import org.apache.tamaya.core.spi.ConfigurationFormat;
 import org.junit.Test;
@@ -41,7 +40,7 @@ public class SimplePropertiesAndCLISample {
 
     @Test
     public void testProgrammatixPropertySet() {
-        System.out.println(PropertySourceBuilder.create("test").addPaths("test", "classpath:test.properties").build());
+        System.out.println(PropertySourceBuilder.of("test").addPaths("test", "classpath:test.properties").build());
     }
 
     @Test
@@ -50,7 +49,7 @@ public class SimplePropertiesAndCLISample {
         Map<String, String> cfgMap = new HashMap<>();
         cfgMap.put("param1", "value1");
         cfgMap.put("a", "Adrian"); // overrides Anatole
-        Configuration config = PropertySourceBuilder.create("myTestConfig").addPaths(
+        Configuration config = PropertySourceBuilder.of("myTestConfig").addPaths(
                 "classpath:test.properties").addPaths("classpath:cfg/test.xml")
                 .addArgs(new String[]{"-arg1", "--fullarg", "fullValue", "-myflag"}).addMap(cfgMap)
                 .build().toConfiguration();
@@ -66,7 +65,7 @@ public class SimplePropertiesAndCLISample {
         System.out.print("--- b=");
         System.out.println(config.get("b"));
         System.out.println("--- only a,b,c)");
-        System.out.println(PropertySourceBuilder.create(config).filter((f) -> f.equals("a") || f.equals("b") || f.equals("c")).build());
+        System.out.println(PropertySourceBuilder.of(config).filter((f) -> f.equals("a") || f.equals("b") || f.equals("c")).build());
     }
 
 }

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/test/java/org/apache/tamaya/ucs/UC1ReadProperties.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/tamaya/ucs/UC1ReadProperties.java b/core/src/test/java/org/apache/tamaya/ucs/UC1ReadProperties.java
index 54e1491..c487bdb 100644
--- a/core/src/test/java/org/apache/tamaya/ucs/UC1ReadProperties.java
+++ b/core/src/test/java/org/apache/tamaya/ucs/UC1ReadProperties.java
@@ -60,7 +60,7 @@ public class UC1ReadProperties {
 
     @Test
     public void example() {
-        Configuration config = PropertySourceBuilder.create("test")
+        Configuration config = PropertySourceBuilder.of("test")
                 .addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build().toConfiguration();
         String name = config.get("name").orElse("Anatole");
         BigDecimal bigNum = config.get("num.BD", BigDecimal.class).orElseThrow(() -> new IllegalStateException("Sorry"));
@@ -75,13 +75,13 @@ public class UC1ReadProperties {
         Map<String, String> areaMap = config.toMap().entrySet().stream()
                 .filter((e) -> e.getKey().startsWith("num."))
                 .collect(Collectors.toMap((e) -> e.getKey().substring("num.".length()), Map.Entry::getValue));
-        Configuration areaConfig = PropertySourceBuilder.create("Test").addMap(areaMap).build().toConfiguration();
+        Configuration areaConfig = PropertySourceBuilder.of("Test").addMap(areaMap).build().toConfiguration();
         System.out.println(areaConfig);
     }
 
     @Test
     public void getConfigurationTest() {
-        PropertySource provider = PropertySourceBuilder.create("Test").addPaths("classpath:barFoo.properties").build();
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:barFoo.properties").build();
         Configuration config = provider.toConfiguration();
         assertNotNull(config);
         assertTrue(config.isEmpty());
@@ -91,7 +91,7 @@ public class UC1ReadProperties {
 
     @Test
     public void readBadPropertiesTest() {
-        PropertySource provider = PropertySourceBuilder.create("Test").addPaths("classpath:barFoo.properties").build();
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:barFoo.properties").build();
         assertNotNull(provider);
         assertTrue(provider.isEmpty());
         assertTrue(provider.keySet().isEmpty());
@@ -100,7 +100,7 @@ public class UC1ReadProperties {
 
     @Test
     public void readPropertiesTest() {
-        PropertySource provider = PropertySourceBuilder.create("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
         assertNotNull(provider);
         assertEquals(provider.get("a").get(), "aValue");
         assertEquals(provider.get("b").get(), "bValue");
@@ -124,7 +124,7 @@ public class UC1ReadProperties {
 
     @Test
     public void readXmlPropertiesTest() {
-        PropertySource provider = PropertySourceBuilder.create("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.xml").build();
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.xml").build();
         assertNotNull(provider);
         assertEquals(provider.get("a-xml").get(), "aFromXml");
         assertEquals(provider.get("b-xml").get(), "bFromXml");
@@ -133,7 +133,7 @@ public class UC1ReadProperties {
 
     @Test
     public void readIniPropertiesTest() {
-        PropertySource provider = PropertySourceBuilder.create("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.ini").build();
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.ini").build();
         assertNotNull(provider);
         assertEquals(provider.get("a.b.c").get(), "abcValue-fromIni");
         assertEquals(provider.get("a.b.b").get(), "abbValue-fromIni");
@@ -145,7 +145,7 @@ public class UC1ReadProperties {
 
     @Test
     public void readAllPropertiesTest() {
-        PropertySource provider = PropertySourceBuilder.create("Test").withAggregationPolicy(AggregationPolicy.IGNORE_DUPLICATES)
+        PropertySource provider = PropertySourceBuilder.of("Test").withAggregationPolicy(AggregationPolicy.IGNORE_DUPLICATES)
                 .addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.*").build();
         assertNotNull(provider);
         // fromMap ini file
@@ -161,7 +161,7 @@ public class UC1ReadProperties {
 
     @Test
     public void checkForAValue() {
-        PropertySource provider = PropertySourceBuilder.create("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
         assertFalse(provider.containsKey("blabla"));
         assertTrue(provider.containsKey("num.BD"));
         assertFalse(provider.get("blabla").isPresent());
@@ -170,7 +170,7 @@ public class UC1ReadProperties {
 
     @Test
     public void checkKeys() {
-        PropertySource provider = PropertySourceBuilder.create("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
         assertEquals(provider.keySet().size(), 16);
         assertTrue(provider.keySet().contains("boolean"));
         assertFalse(provider.keySet().contains("blabla"));
@@ -178,7 +178,7 @@ public class UC1ReadProperties {
 
     @Test
     public void checkToMap() {
-        PropertySource provider = PropertySourceBuilder.create("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
         Map<String, String> map = provider.toMap();
         assertNotNull(map);
         assertEquals(map.size(), 16);
@@ -189,34 +189,34 @@ public class UC1ReadProperties {
 
     @Test
     public void checkMetaInfo() {
-        PropertySource provider = PropertySourceBuilder.create("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
         MetaInfo meta = provider.getMetaInfo();
         assertNotNull(meta);
     }
 
     @Test
     public void checkNeverNull() {
-        PropertySource provider = PropertySourceBuilder.create("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
         assertNotNull(provider.get("blabla"));
         assertNotNull(provider.get("a.b.c"));
     }
 
     @Test
     public void checkUndefined() {
-        PropertySource provider = PropertySourceBuilder.create("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
         assertFalse(provider.get("blabla").isPresent());
         assertTrue(provider.get("a.b.c").isPresent());
     }
 
     @Test
     public void checkPassDefaultValues() {
-        PropertySource provider = PropertySourceBuilder.create("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
         assertEquals("myDefaultValue", provider.get("blabla").orElse("myDefaultValue"));
     }
 
     @Test(expected = IllegalStateException.class)
     public void checkThrowCustomException() {
-        PropertySource provider = PropertySourceBuilder.create("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
+        PropertySource provider = PropertySourceBuilder.of("Test").addPaths("classpath:ucs/UC1ReadProperties/UC1ReadPropertiesTest.properties").build();
         provider.get("blabla").orElseThrow(() -> new IllegalStateException("checkThrowCustomException"));
     }
 }

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/core/src/test/java/org/apache/tamaya/ucs/UC2CombineProperties.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/tamaya/ucs/UC2CombineProperties.java b/core/src/test/java/org/apache/tamaya/ucs/UC2CombineProperties.java
index a463c31..993048b 100644
--- a/core/src/test/java/org/apache/tamaya/ucs/UC2CombineProperties.java
+++ b/core/src/test/java/org/apache/tamaya/ucs/UC2CombineProperties.java
@@ -38,16 +38,16 @@ public class UC2CombineProperties {
      */
     @Test
     public void simpleAggregationTests() {
-        PropertySource props1 = PropertySourceBuilder.create().addPaths("classpath:ucs/UC2CombineProperties/props1.properties").build();
-        PropertySource props2 = PropertySourceBuilder.create().addPaths("classpath:ucs/UC2CombineProperties/props2.properties").build();
-        PropertySource unionOverriding = PropertySourceBuilder.create(props1).withAggregationPolicy(AggregationPolicy.OVERRIDE).addProviders(props2).build();
+        PropertySource props1 = PropertySourceBuilder.of().addPaths("classpath:ucs/UC2CombineProperties/props1.properties").build();
+        PropertySource props2 = PropertySourceBuilder.of().addPaths("classpath:ucs/UC2CombineProperties/props2.properties").build();
+        PropertySource unionOverriding = PropertySourceBuilder.of(props1).withAggregationPolicy(AggregationPolicy.OVERRIDE).addProviders(props2).build();
         System.out.println("unionOverriding: " + unionOverriding);
-        PropertySource unionIgnoringDuplicates = PropertySourceBuilder.create(props1).withAggregationPolicy(AggregationPolicy.IGNORE_DUPLICATES).addProviders(props2).build();
+        PropertySource unionIgnoringDuplicates = PropertySourceBuilder.of(props1).withAggregationPolicy(AggregationPolicy.IGNORE_DUPLICATES).addProviders(props2).build();
         System.out.println("unionIgnoringDuplicates: " + unionIgnoringDuplicates);
-        PropertySource unionCombined = PropertySourceBuilder.create(props1).withAggregationPolicy(AggregationPolicy.COMBINE).addProviders(props2).build();
+        PropertySource unionCombined = PropertySourceBuilder.of(props1).withAggregationPolicy(AggregationPolicy.COMBINE).addProviders(props2).build();
         System.out.println("unionCombined: " + unionCombined);
         try{
-            PropertySourceBuilder.create(props1).withAggregationPolicy(AggregationPolicy.EXCEPTION).addProviders(props2).build();
+            PropertySourceBuilder.of(props1).withAggregationPolicy(AggregationPolicy.EXCEPTION).addProviders(props2).build();
         }
         catch(ConfigException e){
             // expected!
@@ -59,9 +59,9 @@ public class UC2CombineProperties {
      */
     @Test
     public void dynamicAggregationTests() {
-        PropertySource props1 = PropertySourceBuilder.create().addPaths("classpath:ucs/UC2CombineProperties/props1.properties").build();
-        PropertySource props2 = PropertySourceBuilder.create().addPaths("classpath:ucs/UC2CombineProperties/props2.properties").build();
-        PropertySource props = PropertySourceBuilder.create().withAggregationPolicy((k, v1, v2) -> (v1 != null ? v1 : "") + '[' + v2 + "]").withMetaInfo(MetaInfo.of("dynamicAggregationTests"))
+        PropertySource props1 = PropertySourceBuilder.of().addPaths("classpath:ucs/UC2CombineProperties/props1.properties").build();
+        PropertySource props2 = PropertySourceBuilder.of().addPaths("classpath:ucs/UC2CombineProperties/props2.properties").build();
+        PropertySource props = PropertySourceBuilder.of().withAggregationPolicy((k, v1, v2) -> (v1 != null ? v1 : "") + '[' + v2 + "]").withMetaInfo(MetaInfo.of("dynamicAggregationTests"))
                 .aggregate(props1, props2).build();
         System.out.println(props);
     }

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/docs/design/2_CoreConcepts.adoc
----------------------------------------------------------------------
diff --git a/docs/design/2_CoreConcepts.adoc b/docs/design/2_CoreConcepts.adoc
index db949ac..41c2311 100644
--- a/docs/design/2_CoreConcepts.adoc
+++ b/docs/design/2_CoreConcepts.adoc
@@ -23,7 +23,7 @@ the base of all the other mechanisms:
 The API contains the following core concepts/artifacts:
 
 * Literal Key/Value Pairs
-* _PropertyProvider:_ is the the SPI for a source that provides configuration data. A +PropertyProvider+
+* _PropertySource:_ is the the SPI for a source that provides configuration data. A +PropertySource+
      hereby defines
      ** a minimalistic SPI to be implemented by the config data source
      ** provides data key/value pairs in raw format as String key/values only
@@ -36,34 +36,34 @@ The API contains the following core concepts/artifacts:
      ** provides functional extension points (+with,query+)
      ** allows registering/deregistering of change listeners
      ** is the entry point for evaluating the current +Configuration+
-     ** each +PropertyProvider+ can be easily converted into a +Configuration+
+     ** each +PropertySource+ can be easily converted into a +Configuration+
      ** allows configuration entries to be injected
      ** to access configuration _templates_ (annotated interfaces).
      ** Configuration may support mutability by allowing instances of +ConfigChangeSet+ to be passed.
-* _PropertyProviders_ allows to aggregate different property providers. Hereby property providers are
-  seen as sets, which can be combined to new providers using set styled operations (aggregate, intersect, subtract).
-  This allows to model and create composite container providers, to build up more complex configuration models
+* _PropertySourceBuilder_ allows to aggregate different property sources. Hereby property sources are
+  seen as sets, which can be combined to new sources using set styled operations (aggregation, intersection, subtraction).
+  This allows to model and create composite sources, to build up more complex configuration models
   step by step.
-* _MetaInfo_ is provided by each +Configuration, PropertyProvider+ and describes the configuration/provider and its entries.
+* _MetaInfo_ is provided by each +Configuration, PropertySource+ and describes the configuration/provider and its entries.
 * _Environment_ is the base model for modelling the environment and the accessor for getting the current +Environment+ instance.
 * _Annotations_ a set of annotations allows to configure configuration injection on classes or interface (aka config templates).
 
 The SPI contains the following core concepts/artifacts:
 
-* _Bootstrap_ is the delegate singleton that is used by the framework to resolve components. The effective component
-  loading can be accessed by implementing and registering an instance of +ServiceProvider+ using +java.util.ServiceLoader+.
-* All the singleton used explicitly (+PropertyAdapters,PropertyProviders+ are backed up corresponding API interfaces.
+* _ServiceContext_ is the delegate singleton that is used by the framework to resolve components. The effective component
+  loading can be accessed by implementing and registering an instance of +ServiceContextProvider+ using +java.util.ServiceLoader+.
+* All the singleton used explicitly (+PropertyAdapters,Configuration+ are backed up corresponding API interfaces.
   To override a singleton's behaviour the corresponding SPI has to be implemented and registered, so it can be loaded
-  by the current +Bootstrap+ setup (by default ServiceLoader based).
-* Also the singleton used implicitly by +Configuration, Environment, Stage+ are backed up corresponding SPI interfaces.
+  by the current +ServiceContext+ setup (by default ServiceLoader based).
+* Also the singleton used implicitly by +Configuration, Environment+ are backed up corresponding SPI interfaces.
   To override a singleton's behaviour the corresponding SPI has to be implemented and registered, so it can be loaded
-  by the current +Bootstrap+ setup (by default ServiceLoader based).
+  by the current +ServiceContext+ setup (by default ServiceLoader based).
 
 This is also reflected in the main parts of the API, which is quite small:
 
-* +org.apache.tamaya+ contains the main abstractions +Configuration, ConfigOperator, ConfigQuery, PropertyAdapter, Stage,
-  Environment, PropertyProvider, MetaInfo+
-* +org.apache.tamaya.spi+ contains the SPI interfaces to be implemented by implementations and the +Bootstrap+ mechanism.
+* +org.apache.tamaya+ contains the main abstractions +Configuration, ConfigQuery, PropertyAdapter, Stage,
+  Environment, PropertySource, MetaInfo+
+* +org.apache.tamaya.spi+ contains the SPI interfaces to be implemented by implementations and the +ServiceContext+ mechanism.
 + +org.apache.tamaya.annot+ contains the annotations defined.
 
 In the implementation are there are additional projects:
@@ -200,20 +200,20 @@ Nevertheless most of these advantages can be mitigated easily, hereby still keep
 ** The keys of configuration can have additional syntax/semantics. E.g. when adding dor-separating path semantics
 *** trees/maps can also simply be mapped.
 
-[APIPropertyProviders]
-=== Property Providers
+[APIPropertySources]
+=== PropertySource
 ==== Basic Model
 
 We have seen that constrain configuration aspects to simple literal key/value pairs provides us with an easy to
-understand, generic, flexible, yet expendable mechanism. Looking at the Java language features a +vava.util.Map<String,
+understand, generic, flexible, yet expendable mechanism. Looking at the Java language features a +java.util.Map<String,
 String>+ and +java.util.Properties+ basically model these quite well out of the box.
-So it makes sense to build configuration on top of the JDK's +Map+ interface. This creates immediately additional
+So it would make sense to build configuration on top of the JDK's +Map+ interface. This creates immediately additional
 benefits:
 
 * we inherit full Lambda and collection support
 * Maps are widely known and well understood
 
-Nevertheless there are some things to be considered:
+Nevertheless there are some severe drawbacks:
 
 * Configuration also requires meta-data, such as
 ** the origin of a certain configuration entry and how it was derived from other values
@@ -224,12 +224,12 @@ Nevertheless there are some things to be considered:
 ** ...
 
 Basically the same is also the not related to some single configuration key, but also to a whole map.
-The +PropertyProvider+ interface models exact these aspects and looks as illustrated below:
+The +PropertySource+ interface models exact these aspects and looks as illustrated below:
 
 [source,java]
-.Interface PropertyProvider
+.Interface PropertySource
 --------------------------------------------
-public interface PropertyProvider{
+public interface PropertySource{
 
       Optional<String> get(String key);
       boolean containsKey(String key);
@@ -246,20 +246,22 @@ public interface PropertyProvider{
 Hereby
 
 * +getMetaInfo()+ return the meta information for the property provider, as well as for individual property key/value pairs.
-* +get, containsKey, keySet+ look similar to the methods on +Map+, though +get+ uses the +Optional+ type introduced
+* +get+ look similar to the methods on +Map+, though +get+ uses the +Optional+ type introduced
   with Java 8. This avoids returning +null+ or throwing exceptions in case no such entry is available and also
   reduced the API's footprint, since default values can be easily implemented by calling +Optional.orElse+.
+* +containsKey, keySet+ are as well methods similar to +java.util.Map+ though implementations may only returns
+  limited data, especially when the underlying map storage does not support iteration.
 * +isMutable()+ allows to easy check, if a property provider is mutable, which is more elegant than catching
   +NonSupportedOperation+ exception thrown on the according methods of +Map+.
 * +load()+ finally allows to (re)load a property map. It depends on the implementing source, if this operation
   has any effect. If the map changes an according +ConfigChange+ must be returned, describing the
   changes applied.
-* +hasSameProperties+ allows to perform a comparison with another provider.
-* +toMap+ allows to extract thing to a +Map+.
+* +toMap+ allows to extract thing to a +Map+. Similar to +containsKey, keySet+ implementations may only return
+  a limited data map, especially when the underlying map storage does not support iteration.
 
 This simple model will be used within the spi, where configuration can be injected/provided from external resources.
 But we have seen, that we have to consider additional aspects, such as extendability and type safety. Therefore we
-extend +PropertyMap+ and hereby also apply the 'composite pattern', which results in the following key abstraction.
+extend +PropertySource+ and hereby also apply the 'composite pattern', which results in the following key abstraction.
 
 ==== Meta Information
 
@@ -268,7 +270,7 @@ Each instance also provides an instance of +MetaInfo+, which provides meta infor
 [source,java]
 .Accessing Meta Information
 --------------------------------------------
-PropertyProvider prov = ...;
+PropertySource prov = ...;
 MetaInfo metaInfo = prov.getMetaInfo();
 Set<String> keys = metaInfo.keySet();  // returns the attribute keys, for which meta-information is accessible.
 String metaData = metaInfo.get("a.b.c.value"); // access meta information
@@ -280,32 +282,32 @@ As we have seen above there is as well a +MetaInfoBuilder+, which must be used t
 
 ==== Mutability
 
-Property providers optionally may be mutable. This can be checked by calling +boolean isMutable()+. If a provider
-is mutable a +ConfigChangeSet+ can be passed. This change set can then be applied by the provider. On creation
-of the +ConfigChangeSetBuilder+ a provider can pass version information, so _optimistic locking_ can be implemented
+Property sources optionally may be mutable. This can be checked by calling +boolean isMutable()+. If a source
+is mutable a +ConfigChangeSet+ can be passed. This change set can then be applied by the source. On creation
+of the +ConfigChangeSetBuilder+ a source can pass version information, so _optimistic locking_ can be implemented
 easily:
 
 [source,java]
-.Creating and applying a +ConfigChangeSet+ to a provider
+.Creating and applying a +ConfigChangeSet+ to a PropertySource
 --------------------------------------------
-PropertyProvider prov = ...;
+PropertySource source = ...;
 ConfigChangeSet changeSet = ConfigChangeSetBuilder.of(provider)  // creating a default version
    .remove("key1ToBeRemoved", +key2ToBeRemoved")
    .put("key2", "key2Value")
    .put("key3", 12345)
    .put("key4", 123.45)
    .build();
-provider.apply(changeSet);
+source.apply(changeSet);
 --------------------------------------------
 
-[[API CombineProviders]]
-==== Combining Property Providers
+[[API PropertySourceBuilder]]
+==== Building Property Sources
 
 Looking at the structures of configuration system used by large companies we typically encounter some kind of configuration
 hierarchies that are combined in arbitrary ways. Users of the systems are typically not aware of the complexities in this
 area, since they simply know the possible locations, formats and the overriding policies. Framework providers on the other
 side must face the complexities and it would be very useful if Tamaya can support here by providing prebuilt functionality
-that helps implementing these aspects. All this leads to the feature set of combining property providers. Hereby the following
+that helps implementing these aspects. All this leads to the feature set of combining property sources. Hereby the following
 strategies are useful:
 
 * aggregating providers, hereby later providers added
@@ -318,7 +320,7 @@ strategies are useful:
 * subtracting providers
 * filtering providers
 
-These common functionality is provided by the +PropertyProviders+ singleton. Additionally to the base strategies above a +MetaInfo+
+These common functionality is provided by the +PropertySources+ singleton. Additionally to the base strategies above a +MetaInfo+
 instance can be passed optionally as well to define the meta information for the newly created provider instances.
 Let's assume we have two property providers with the following data:
 
@@ -348,26 +350,26 @@ Looking in detail you see that the entries +a,b,c+ are present in both providers
 and +g,h,i+ only in provider 2.
 
 [source,java]
-.Example Combining PropertyProviders
+.Example Combining PropertySources
 --------------------------------------------
-PropertyProvider provider1 = ...
-PropertyProvider provider2 = ...
+PropertySource provider1 = ...
+PropertySource provider2 = ...
 
 // aggregate, hereby values from provider 2 override values from provider 1
-PropertyProvider unionOverriding = PropertyProviders.aggregate(AggregationPolicy.OVERRIDE(), provider1, provider2);
+PropertySource unionOverriding = PropertySources.aggregate(AggregationPolicy.OVERRIDE(), provider1, provider2);
 System.out.println("unionOverriding: " + unionOverriding);
 
 // ignore duplicates, values present in provider 1 are not overriden by provider 2
-PropertyProvider unionIgnoringDuplicates = PropertyProviders.aggregate(AggregationPolicy.IGNORE_DUPLICATES(), provider1, provider2);
+PropertySource unionIgnoringDuplicates = PropertySources.aggregate(AggregationPolicy.IGNORE_DUPLICATES(), provider1, provider2);
 System.out.println("unionIgnoringDuplicates: " + unionIgnoringDuplicates);
 
 // this variant combines/maps duplicate values into a new value
-PropertyProvider unionCombined = PropertyProviders.aggregate(AggregationPolicy.COMBINE(), provider1, provider2);
+PropertySource unionCombined = PropertySources.aggregate(AggregationPolicy.COMBINE(), provider1, provider2);
 System.out.println("unionCombined: " + unionCombined);
 
 // This variant throws an exception since there are key/value paris in both providers, but with different values
 try{
-    PropertyProviders.aggregate(AggregationPolicy.EXCEPTION(), provider1, provider2);
+    PropertySources.aggregate(AggregationPolicy.EXCEPTION(), provider1, provider2);
 }
 catch(ConfigException e){
     // expected!
@@ -377,9 +379,9 @@ catch(ConfigException e){
 The example above produces the following outpout:
 
 [source,listing]
-.Example Combining PropertyProviders
+.Example Combining PropertySources
 --------------------------------------------
-AggregatedPropertyProvider{
+AggregatedPropertySource{
   (name = dynamicAggregationTests)
   a = "[a][A]"
   b = "[b][B]"
@@ -391,7 +393,7 @@ AggregatedPropertyProvider{
   h = "[h]"
   i = "[i]"
 }
-unionOverriding: AggregatedPropertyProvider{
+unionOverriding: AggregatedPropertySource{
   (name = <noname>)
   a = "A"
   b = "B"
@@ -403,7 +405,7 @@ unionOverriding: AggregatedPropertyProvider{
   h = "h"
   i = "i"
 }
-unionIgnoringDuplicates: AggregatedPropertyProvider{
+unionIgnoringDuplicates: AggregatedPropertySource{
   (name = <noname>)
   a = "a"
   b = "b"
@@ -415,7 +417,7 @@ unionIgnoringDuplicates: AggregatedPropertyProvider{
   h = "h"
   i = "i"
 }
-unionCombined: AggregatedPropertyProvider{
+unionCombined: AggregatedPropertySource{
   (name = <noname>)
   a = "a,A"
   b = "b,B"
@@ -445,9 +447,9 @@ So we can also define our own aggregation strategy using a Lambda expression:
 [source,java]
 .Use a Custom AggregationPolicy
 --------------------------------------------
-PropertyProvider provider1 = ...;
-PropertyProvider provider2 = ...;
-PropertyProvider props = PropertyProviders.aggregate(
+PropertySource provider1 = ...;
+PropertySource provider2 = ...;
+PropertySource props = PropertySources.aggregate(
       (k, v1, v2) -> (v1 != null ? v1 : "") + '[' + v2 + "]",
       MetaInfo.of("dynamicAggregationTests"),
       props1, props2);
@@ -459,7 +461,7 @@ Additionally we also pass here an instance of +MetaInfo+. The output of this cod
 [source,listing]
 .Listing of dynamic aggregation policy
 --------------------------------------------
-AggregatedPropertyProvider{
+AggregatedPropertySource{
   (name = dynamicAggregationTests)
   a = "[a][A]"
   b = "[b][B]"
@@ -473,54 +475,54 @@ AggregatedPropertyProvider{
 }
 --------------------------------------------
 
-Summarizing the +PropertyProviders+ singleton allows to combine providers in various forms:
+Summarizing the +PropertySources+ singleton allows to combine providers in various forms:
 
 [source,listing]
-.Methods provided on PropertyProviders
---------------------------------------------
-public final class PropertyProviders {
-
-    private PropertyProviders() {}
-
-    public static PropertyProvider fromArgs(String... args) {
-    public static PropertyProvider fromArgs(MetaInfo metaInfo, String... args) {
-    public static PropertyProvider fromPaths(AggregationPolicy aggregationPolicy, String... paths) {
-    public static PropertyProvider fromPaths(String... paths) {
-    public static PropertyProvider fromPaths(List<String> paths) {
-    public static PropertyProvider fromPaths(AggregationPolicy aggregationPolicy, List<String> paths) {
-    public static PropertyProvider fromPaths(MetaInfo metaInfo, List<String> paths) {
-    public static PropertyProvider fromPaths(AggregationPolicy aggregationPolicy, MetaInfo metaInfo, List<String> paths) {
-    public static PropertyProvider fromUris(URI... uris) {
-    public static PropertyProvider fromUris(AggregationPolicy aggregationPolicy, URI... uris) {
-    public static PropertyProvider fromUris(List<URI> uris) {
-    public static PropertyProvider fromUris(AggregationPolicy aggregationPolicy, List<URI> uris) {
-    public static PropertyProvider fromUris(MetaInfo metaInfo, URI... uris) {
-    public static PropertyProvider fromUris(AggregationPolicy aggregationPolicy, MetaInfo metaInfo, URI... uris) {
-    public static PropertyProvider fromUris(MetaInfo metaInfo, List<URI> uris) {
-    public static PropertyProvider fromUris(AggregationPolicy aggregationPolicy, MetaInfo metaInfo, List<URI> uris) {
-    public static PropertyProvider fromMap(Map<String, String> map) {
-    public static PropertyProvider fromMap(MetaInfo metaInfo, Map<String, String> map) {
-    public static PropertyProvider empty() {
-    public static PropertyProvider emptyMutable() {
-    public static PropertyProvider empty(MetaInfo metaInfo) {
-    public static PropertyProvider emptyMutable(MetaInfo metaInfo) {
-    public static PropertyProvider fromEnvironmentProperties() {
-    public static PropertyProvider fromSystemProperties() {
-    public static PropertyProvider freezed(PropertyProvider provider) {
-    public static PropertyProvider aggregate(AggregationPolicy mapping, MetaInfo metaInfo, PropertyProvider... providers){
-    public static PropertyProvider aggregate(PropertyProvider... providers) {
-    public static PropertyProvider aggregate(List<PropertyProvider> providers) {
-    public static PropertyProvider aggregate(AggregationPolicy mapping, PropertyProvider... propertyMaps) {
-    public static PropertyProvider aggregate(AggregationPolicy mapping, List<PropertyProvider> providers) {
-    public static PropertyProvider mutable(PropertyProvider provider) {
-    public static PropertyProvider intersected(AggregationPolicy aggregationPolicy, PropertyProvider... providers) {
-    public static PropertyProvider intersected(PropertyProvider... providers) {
-    public static PropertyProvider subtracted(PropertyProvider target, PropertyProvider... providers) {
-    public static PropertyProvider filtered(Predicate<String> filter, PropertyProvider provider) {
-    public static PropertyProvider contextual(Supplier<PropertyProvider> mapSupplier,
+.Methods provided on PropertySources
+--------------------------------------------
+public final class PropertySources {
+
+    private PropertySources() {}
+
+    public static PropertySource fromArgs(String... args) {
+    public static PropertySource fromArgs(MetaInfo metaInfo, String... args) {
+    public static PropertySource fromPaths(AggregationPolicy aggregationPolicy, String... paths) {
+    public static PropertySource fromPaths(String... paths) {
+    public static PropertySource fromPaths(List<String> paths) {
+    public static PropertySource fromPaths(AggregationPolicy aggregationPolicy, List<String> paths) {
+    public static PropertySource fromPaths(MetaInfo metaInfo, List<String> paths) {
+    public static PropertySource fromPaths(AggregationPolicy aggregationPolicy, MetaInfo metaInfo, List<String> paths) {
+    public static PropertySource fromUris(URI... uris) {
+    public static PropertySource fromUris(AggregationPolicy aggregationPolicy, URI... uris) {
+    public static PropertySource fromUris(List<URI> uris) {
+    public static PropertySource fromUris(AggregationPolicy aggregationPolicy, List<URI> uris) {
+    public static PropertySource fromUris(MetaInfo metaInfo, URI... uris) {
+    public static PropertySource fromUris(AggregationPolicy aggregationPolicy, MetaInfo metaInfo, URI... uris) {
+    public static PropertySource fromUris(MetaInfo metaInfo, List<URI> uris) {
+    public static PropertySource fromUris(AggregationPolicy aggregationPolicy, MetaInfo metaInfo, List<URI> uris) {
+    public static PropertySource fromMap(Map<String, String> map) {
+    public static PropertySource fromMap(MetaInfo metaInfo, Map<String, String> map) {
+    public static PropertySource empty() {
+    public static PropertySource emptyMutable() {
+    public static PropertySource empty(MetaInfo metaInfo) {
+    public static PropertySource emptyMutable(MetaInfo metaInfo) {
+    public static PropertySource fromEnvironmentProperties() {
+    public static PropertySource fromSystemProperties() {
+    public static PropertySource freezed(PropertySource provider) {
+    public static PropertySource aggregate(AggregationPolicy mapping, MetaInfo metaInfo, PropertySource... providers){
+    public static PropertySource aggregate(PropertySource... providers) {
+    public static PropertySource aggregate(List<PropertySource> providers) {
+    public static PropertySource aggregate(AggregationPolicy mapping, PropertySource... propertyMaps) {
+    public static PropertySource aggregate(AggregationPolicy mapping, List<PropertySource> providers) {
+    public static PropertySource mutable(PropertySource provider) {
+    public static PropertySource intersected(AggregationPolicy aggregationPolicy, PropertySource... providers) {
+    public static PropertySource intersected(PropertySource... providers) {
+    public static PropertySource subtracted(PropertySource target, PropertySource... providers) {
+    public static PropertySource filtered(Predicate<String> filter, PropertySource provider) {
+    public static PropertySource contextual(Supplier<PropertySource> mapSupplier,
                                               Supplier<String> isolationKeySupplier) {
-    public static PropertyProvider delegating(PropertyProvider mainMap, Map<String, String> parentMap) {
-    public static PropertyProvider replacing(PropertyProvider mainMap, Map<String, String> replacementMap) {
+    public static PropertySource delegating(PropertySource mainMap, Map<String, String> parentMap) {
+    public static PropertySource replacing(PropertySource mainMap, Map<String, String> replacementMap) {
 }
 --------------------------------------------
 
@@ -529,13 +531,13 @@ public final class PropertyProviders {
 === Configuration
 ==== Basic Model
 
-Configuration inherits all basic features from +PropertyProvider+, but additionally adds functionality for
+Configuration inherits all basic features from +PropertySource+, but additionally adds functionality for
 type safety and extension mechanisms:
 
 [source,java]
 .Interface Configuration
 --------------------------------------------
-public interface Configuration extends PropertyProvider{
+public interface Configuration extends PropertySource{
 
     default OptionalBoolean getBoolean(String key);
     default OptionalInt getInteger(String key);
@@ -594,7 +596,7 @@ Hereby
 [[TypeConversion]]
 ==== Type Conversion
 
-Configuration extend +PropertyProvider+ and add additional support for non String types. This is achieved
+Configuration extend +PropertySource+ and add additional support for non String types. This is achieved
 with the help of +PropertyAdapter+ instances:
 
 [source,java]

http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/123a4afc/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/TestConfigProvider.java
----------------------------------------------------------------------
diff --git a/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/TestConfigProvider.java b/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/TestConfigProvider.java
index 8ab08ae..6c92379 100644
--- a/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/TestConfigProvider.java
+++ b/modules/integration/cdi/src/test/java/org/apache/tamaya/integration/cdi/TestConfigProvider.java
@@ -49,7 +49,7 @@ public class TestConfigProvider implements ConfigurationProviderSpi
         config.put("BD", "123456789123456789123456789123456789.123456789123456789123456789123456789");
         config.put("testProperty", "value current testProperty");
         config.put("runtimeVersion", "${java.version}");
-        testConfig = PropertySourceBuilder.create("test").addMap(config).build().toConfiguration();
+        testConfig = PropertySourceBuilder.of("test").addMap(config).build().toConfiguration();
     }
 
     @Override


Mime
View raw message